A powerful cross-platform UI toolkit for building native-quality iOS, Android, and Progressive Web Apps with HTML, CSS, and JavaScript.
51.11k
stars
13.5k
forks
source link
bug: Scroll position not restored when navigating back #29578
Open
Julien-Marcou opened 5 months ago
Prerequisites
Ionic Framework Version
v8.x
Current Behavior
Scroll position is not restored when I navigate back to the previous page, it scrolls me to the top of the page
It's really annoying when you want to open the details of an item, then go back, then want to open another item details, etc...
Expected Behavior
In v7 of Ionic, it would keep the previous scroll position, so that navigating back and forth between pages was smooth
Steps to Reproduce
I forked the stackblitz demo of https://ionicframework.com/docs/api/nav#using-navlink and just added some fake content so that the page are tall enough to be scrollable.
Steps:
It was not the case in Ionic v7
Code Reproduction URL
https://stackblitz.com/edit/ultfxy?file=index.html
Ionic Info
Additional Information
No response