react-router-scroll-memory icon indicating copy to clipboard operation
react-router-scroll-memory copied to clipboard

Scroll restore before data loads in

Open dominik-myszkowski opened this issue 4 years ago • 1 comments

The scroll restore happens immediately after page has been shifted to previous one, not allowing the data to load on page (and not allowing to scroll yet). It would be nice to expose some kind of method which will be used once the data has been loaded and that would trigger the scroll to correct position. For example my shop has a list of products provided by GraphQL query. When user clicks on a product a new page loads with product details. When user swiches back to the list the products load again from graphQL and only then (graphql query onComplete) can I scroll back to correct position.

dominik-myszkowski avatar Dec 31 '20 10:12 dominik-myszkowski

@dominik-myszkowski Did you find and work around?

ashokkumar88 avatar Oct 08 '22 08:10 ashokkumar88