Reputation: 2257
Imaging a page (vertical scrollable) full of thumbnails of images. When clicking on a thumbnail the image opens in fullscreen.
It has a <Link />
which leads back to the thumbnail page. Currently this leads to the top of the thumbnail page.
How can I instead link to the last scroll position?
Upvotes: 1
Views: 969
Reputation: 4008
As you know which thumbnail you just displayed, you could set an id on them, and when you click back to the thumbnail page, you can make the page scroll to the position of the last displayed id/image.
Upvotes: 2