Scroll behaviour when using Prefetch + ssr

  •     scrollBehavior: () => ({ x: 0, y: 0 }),

    ScrollBehaviour was working as expected, navigating the user to the top on route entry.

    However, after implementing preFetching this behaviour doesn’t work any more. instead, the scroll posiition is preserved from the previous router.
    Any idea why this is happening?
    EDIT: After further debugging the problem seems to be related to quasar Loading plugin
    this is the prefetch hook where I call Loading

      preFetch({ store }) {;
        return store.dispatch("getDoctors").then(success => {

  • I have the same problem

  • I noticed they are using preventScroll in the Loading.js file and this is apparently the bug source, when I removed it to test, the scrolling worked as expected

Log in to reply