Page reloads on link clicks? Classic.
If you’re using vanilla JS, make sure you’re not mixing up `innerHTML` or `window.location` calls. Those can force a refresh.
Alternatively, try using `fetch()` to load content dynamically and update the DOM without a full page reload.
Here’s a quick example:
```js
document.querySelector('a').addEventListener('click', async (e) => {
e.preventDefault();
const response = await fetch('/some-url');
document.body.innerHTML = await response.text();
});
```
If you’re using vanilla JS, make sure you’re not mixing up `innerHTML` or `window.location` calls. Those can force a refresh.
Alternatively, try using `fetch()` to load content dynamically and update the DOM without a full page reload.
Here’s a quick example:
```js
document.querySelector('a').addEventListener('click', async (e) => {
e.preventDefault();
const response = await fetch('/some-url');
document.body.innerHTML = await response.text();
});
```
