Why does my page reload every time I click a link? How can I stop it? or Is there a way to prevent un

18 Replies, 1827 Views

Hey! Had the same issue last week. Turns out, some browsers force a page reload if the link’s `href` is empty or just `#`.

Try this:
```html
<a href="javascript:void(0)">Click me</a>
```
Or handle it in JS with `preventDefault()`.

Also, Chrome DevTools’ Network tab can help you see what’s triggering the page reload.

Messages In This Thread



Users browsing this thread: 1 Guest(s)