We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2b1e45d commit 9fb3fb7Copy full SHA for 9fb3fb7
src/router/index.js
@@ -39,7 +39,9 @@ const routes = [
39
const router = createRouter({
40
history: createWebHistory(),
41
routes,
42
- scrollBehavior() { document.getElementsByTagName('html')[0].scrollIntoView() }
+ scrollBehavior(to) {
43
+ if (!to.params.saveScrollPos) { document.getElementsByTagName('html')[0].scrollIntoView() }
44
+ }
45
})
46
47
router.beforeEach(to => {
0 commit comments