index.js 255 B

12345678910111213141516
  1. import Vue from 'vue'
  2. import Vuex from 'vuex'
  3. Vue.use(Vuex)
  4. const store = new Vuex.Store({
  5. state: {
  6. "token":''
  7. },
  8. mutations: {
  9. addtoken(state, data) {
  10. console.log(1111)
  11. state.token = data;
  12. }
  13. },
  14. actions: {}
  15. })
  16. export default store