preserve history properly; fixes #1374

This commit is contained in:
Cory LaViska
2025-10-15 14:49:51 -04:00
parent 6e380eb2da
commit c5b417d888

View File

@@ -34,7 +34,8 @@ document.addEventListener('click', event => {
top: target.offsetTop - headerHeight,
behavior: 'smooth',
});
history.pushState(undefined, undefined, `#${id}`);
history.replaceState(history.state, '', `#${id}`);
}
}
});