How can pages opened by localtion.href in a vue project be cached by router?

Project is an H5 page, nested in Mini Program

A page is a list loaded at the bottom of the scroll

B page is a detail page

When the

A page clicks on an item, use location.href ="/ b"to jump to page B
(because when Mini Program uses the forwarding feature, he can only use location.href to get the shared content)

so far there is no problem.
there is a requirement below that the B page clicks the back button to return to the location you browsed before page A. Then there is a problem. Page B uses router.back (- 1), jumping to page An is a new request, and keep-alive is useless. I would like to ask how this situation can read the cache of the A page.


the idea is to store the number of pages and scrolling height of the A page before jumping to the details page, and use js to scroll to the original location when returning from the details page.

provide a help link: detail page returns how the list page records the user's browsing location and updates the detail view

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1c1f294-560a8.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1c1f294-560a8.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?