3 ms·
Yes, this! People seem not to know when to use replaceState over pushState. And in my eyes this is a clear candidate for replaceState. (There are also examples
by fphilipe 11y ago
Yes, this! People seem not to know when to use replaceState over pushState. And in my eyes this is a clear candidate for replaceState. (There are also examples the other way around, such as GitHub's PR tabs, drives me insane every time.)
- joemcelroy 11y agoYes! Thanks for noticing a side effect of the way we update our url. It should be replaceState for the search box. Other actions like pagination, applying filters and sorting should be pushState however. We also throttle the searchbox search requests as you type.