index.js 412 B

123456789101112131415161718192021
  1. import Vue from 'vue'
  2. import Vuex from 'vuex'
  3. import user from './modules/user.js'
  4. import activity from './modules/activity'
  5. import report from './modules/report'
  6. import audio from './modules/audio'
  7. Vue.use(Vuex);//vue的插件机制
  8. //Vuex.Store 构造器选项
  9. const store = new Vuex.Store({
  10. state:{},
  11. mutations:{},
  12. actions:{},
  13. modules:{
  14. user,
  15. activity,
  16. report,
  17. audio
  18. }
  19. })
  20. export default store