Remember positions on scroll.
This commit is contained in:
parent
2341a3692a
commit
ce0071d6e0
@ -30,7 +30,10 @@ const routes = [
|
||||
|
||||
const router = new VueRouter({
|
||||
mode: 'history',
|
||||
routes
|
||||
routes,
|
||||
scrollBehavior: (to, from, savedPosition) => {
|
||||
return savedPosition || { x: 0, y: 0 }
|
||||
}
|
||||
})
|
||||
|
||||
/* eslint-disable no-new */
|
||||
|
Loading…
Reference in New Issue
Block a user