3 ms·
Thanks! It should be doing that, if it’s not, it’s a bug. Drop me a note at matt at stackoverflow dot com, with a repro?
by mwsherman 10y ago
Thanks! It should be doing that, if it’s not, it’s a bug. Drop me a note at matt at stackoverflow dot com, with a repro?
- nalllar 10y agoUse history.replaceState instead of pushState: https://developer.mozilla.org/en-US/docs/Web/API/History_API https://developer.mozilla.org/en-US/docs/Web/API/History_API That will still change the address in the location bar without filling up the history so it takes many back button clicks to leave.
- notyourwork 10y agoThis reply would be much more comical if you linked to a stackoverflow thread about history.replaceState. :)
- SmellTheGlove 10y agoMatt, you have been downgraded to a 1. :)
- mwsherman 10y ago+1 not just for the comment but for the Spinal Tap reference.
- mwsherman 10y agoActually I read this wrong. We decided on pushState deliberately, since it’s essentially a form submission, and so a history entry. That said, one of our folks suggested same so I think from a UX perspective, we could go either way. It doesn’t _feel_ like a form submission, one could argue.