No More Posting New Topics!

If you have a question or an issue, please start a thread in our Github Discussions Forum.
This forum is closed for new threads/ topics.

Navigation

    Quasar Framework

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    VueAuthenticate and $auth var

    Help
    2
    3
    1373
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • D
      diegomagikal last edited by

      I’m migrating my app from v 0.14 to 0.15 and I facing a lot of problems.

      First, I created a plugin named vueauthenticate.js with code:

      import Vue from 'vue'
      import axios from 'axios';
      import VueAxios from 'vue-axios'
      import VueAuthenticate from 'vue-authenticate'
      
      export default ({ Vue }) => {
      
        Vue.use(VueAuthenticate, {
              baseUrl: '/login'          
              })
      }
      

      So, I put vueauthenticate in quasar.conf.js plugins. All dependencies are installed.

      But when I check the console, the var $auth is present in Vue but with message: Exception: Error: Request handler instance not found! at Vue.get (webpack-internal:///./node_modules/vue-authenticate/dist/vue-authenticate.es2015.js:1405:19) at Vue.remoteFunction (<anonymous>:2:14) . Obviously, nothing works.

      Request handler instance not found

      Any idea? Thanks

      1 Reply Last reply Reply Quote 0
      • C
        chbarr last edited by

        Maybe you must tell Vue to use VueAxios just before Vue.use(VueAuthenticate):

        Vue.use(VueAxios, axios)
        
        D 1 Reply Last reply Reply Quote 0
        • D
          diegomagikal @chbarr last edited by

          @chbarr Solved! Many thanks! 😃

          1 Reply Last reply Reply Quote 0
          • First post
            Last post