Loading src/router.js +5 −2 Original line number Diff line number Diff line Loading @@ -8,8 +8,11 @@ Vue.use(Router) const router = new Router({ mode: 'history', base: process.env.BASE_URL, scrollBehavior () { return { x: 0, y: 0 } scrollBehavior (to, from) { return { x: 0, y: from.name === to.name ? document.scrollingElement.scrollTop : 0 } }, routes: [ { Loading Loading
src/router.js +5 −2 Original line number Diff line number Diff line Loading @@ -8,8 +8,11 @@ Vue.use(Router) const router = new Router({ mode: 'history', base: process.env.BASE_URL, scrollBehavior () { return { x: 0, y: 0 } scrollBehavior (to, from) { return { x: 0, y: from.name === to.name ? document.scrollingElement.scrollTop : 0 } }, routes: [ { Loading