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, 2049 Views

Dude, check if your server is redirecting the link. Sometimes a 301/302 redirect can cause an unwanted page reload.

Open DevTools (F12), go to the Network tab, and see what happens when you click the link. If it’s a redirect, you might need to fix your backend logic.

Also, `preventDefault()` is your best friend here.

Messages In This Thread



Users browsing this thread: 1 Guest(s)