4 ms·
Yelp does this with its photo gallery, and it's really annoying. When the user is in a linear sequence such as a slide deck, photo gallery or similar, the "pre
by lobster_johnson 12y ago
Yelp does this with its photo gallery, and it's really annoying.
When the user is in a linear sequence such as a slide deck, photo gallery or similar, the "previous"/"next" buttons don't map to the browser's back/forward buttons, they navigate the sequence. Littering the history with the navigation history of this sequence does not make sense.
However, it'd be nice if browsers could perhaps record the history (perhaps as some kind of sub-tree history), allowing me to see that I not only visited this slide deck, but that I also visited these specific slides.
- Touche 12y agoThere's no real distinction. If the slides were implemented as separate pages you would get a new entry in your history as you navigate through each of them. Back doesn't mean to go back to the previous domain; it means the previous page. You don't think the slides should be separate pages, but that would mean you couldn't link to them.
- lobster_johnson 12y agoAnd that's bad. A lot of people pine for the simplicity of the early days of the web, but single-page pagination was arguably even more horribly broken then.
- leeoniya 12y agowith replaceState, you get the best of both worlds - bookmarkable slides and no history foo.
- nilliams 12y agoExcept you can accidentally exit the deck when you actually meant to just go to the previous slide. I don't think this is better personally. I prefer the use of pushState and back button taking me to the previous slide. If I really want to back all the way out of the slide deck I will notice after a couple of clicks I need to do something further to go 'all the way back' and right click the back button and click a 'non-slide-deck' selection from that menu.