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

    Import Packages such as vue-validator

    Framework
    3
    3
    1421
    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.
    • N
      Nickk2 last edited by

      Hi,

      I am having a issue importing the vue-validator. Where would I import them?
      Currently I put it in the router.js as
      import VueValidator from ‘vue-validator’
      Vue.use(VueValidator)

      1 Reply Last reply Reply Quote 0
      • Gianni
        Gianni last edited by Gianni

        I imported them directly on main.js to keep an overview off all the imports.

        here is my working example of vue-resource.

        import Vue from 'vue'
        import Quasar from 'quasar'
        import router from './router'
        import VueResource from 'vue-resource'
        
        Vue.use(Quasar) // Install Quasar Framework
        Vue.use(VueResource)
        
        1 Reply Last reply Reply Quote 0
        • rstoenescu
          rstoenescu Admin last edited by

          @Nickk2 Like Gianni correctly indicated, it’s best to import packages in main.js. One comment though. I’d use Vuelidate instead of vue-validator. Much more clean and it will go very smooth with the pending improved form changes that will soon be released for Quasar.

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