Navigation

    Quasar Framework

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    1. Home
    2. Tags
    3. vuex
    Log in to post

    • T

      Cordova Plugin not working in Vuex files
      Help • vuex cordova-plugin import • • tc  

      11
      0
      Votes
      11
      Posts
      28
      Views

      T

      @dobbel Yes, I even added it to the window scope. Problem more likely the priority of loading the plugin. When the quasar start, it tend to loaded the vuex store before cordova plugin did, hence it will get undefined in state.js .
    • M

      Unable to use this.$axios in Vuex: TS2339: Property '$axios' does not exist on type 'Store '.
      Framework • vuex typescript axios • • Maxiride  

      11
      0
      Votes
      11
      Posts
      50
      Views

      Hawkeye64

      @ytsejam I think it is used as “this._vm.axios”, but did not work for me I have found this boot solution. For one thing, you would need to access it as: this._vm.$axios because you put a $ in front on the prototype definition Second, I don’t know how you are writing your functions but the this will be inforrect if you used fat arrow (=>) – they need to be functions for this to be referencing the store.
    • R

      Where to initialize Vuex store at app start up?
      Help • vuex init acessing store • • rhscjohn  

      5
      0
      Votes
      5
      Posts
      50
      Views

      metalsadman

      @dobbel yes because it’s a function, in the boot is different, the store instance is passed as a parameter it’s the same store instance in your src/store/index.js, you’ll get more context if you check .quasar/client-entry.js file (if I’m not wrong), to see how those are initialized, you’ll also see there why $router instance is accessible in your stores via this.$router (if you are using function instead of arrows). I suggest you check that folder out in your project.
    • T

      TypeScript error when using this.$router in actions.ts
      Framework • vuex typescript vue-router firebase • • tempted2use  

      3
      0
      Votes
      3
      Posts
      44
      Views

      I

      Hey! Im having the same problem, but I would like to know why I cannot just import Router inside actions.ts and use it as I usually did on Javascript files. I know that it is something related to the router Quasar wrapper and I am getting really stuck on understanding why is this happening. Thank you.
    • I

      vuex mutations not working as expected
      Help • vuex mutations • • ioncoder  

      6
      0
      Votes
      6
      Posts
      70
      Views

      dobbel

      @BillD http://shzhangji.com/blog/2018/04/17/form-handling-in-vuex-strict-mode/ I think the ‘Computed Property’ way with get/set is the best approach. So you can still use v-model.
    • J

      spread operator in vuex not working with any presets
      Help • vuex babel presets quasar 1.4 • • jorgv  

      3
      0
      Votes
      3
      Posts
      85
      Views

      J

      Hi @metalsadman thanks for answering, After you mentioned if I had vuex in the project I search more than I had it installed but I was importing the function wrong import { ...mapGetters } from 'vuex'; I fixt the error by importing it right. thanks again and sorry
    • N

      vuex getters actions
      Framework • vuex quasar vuex getters • • nazemi-sfa  

      6
      1
      Votes
      6
      Posts
      701
      Views

      king_of_leon

      ok thanks
    • D

      Loading firebase user identity before everything else?
      Help • vuex firebase auth • • darshie  

      5
      0
      Votes
      5
      Posts
      722
      Views

      T

      @darshie the function is called slighly different in 0.17 my code is for v1 forgot to say LocalStorage.get.item(key) https://quasar-framework.org/components/web-storage.html#Getting-Started
    • R

      Access $i18n in vuex action
      Framework • vuex i18n • • reath  

      4
      0
      Votes
      4
      Posts
      826
      Views

      s.molinari

      Well, Quasar’s i18n is “native” to its components, meaning, the languages available and the i18n system is only for Quasar’s components. Needing the i18n object outside of the components is basically not necessary. You set it once in, say, a layout component and you are good to go for all further components, as the docs explain. Scott
    • S

      Solved: Vuex actions this.$
      Help • vuex • • silentcoast  

      3
      2
      Votes
      3
      Posts
      1398
      Views

      benoitranque

      Couple ways to go about it. One is to add a named export to your plugins and import that in stores. Another is to pass the vue instance to the store when dispatching actions Edit: You can access the vue instance from the store using this._vm
    • D

      q-uploader and vuex?
      Help • vuex q-uploader images • • Diferno  

      2
      0
      Votes
      2
      Posts
      1158
      Views

      S

      @Diferno said in q-uploader and vuex?: n my Vuex store I hi, Diferno can you plz share your code how you configure additionalFields in q-uploader. and how you receive that field from server side. thanks.
    • G

      Some components not really Vuex friendly
      Framework • vuex modal • • genyded  

      6
      2
      Votes
      6
      Posts
      2069
      Views

      G

      https://github.com/quasarframework/quasar/issues/479
    • Dobromir

      Proper way of using Quasar with Vuex
      Help • vuex • • Dobromir  

      5
      0
      Votes
      5
      Posts
      8319
      Views

      D

      And what about “tracking” the modal state itself? (opened/closed) and their acctions? (open, cancel, accept, etc.)