import Vue from 'vue' import Vuex from 'vuex' //引入vuex插件 进行状态管理 Vue.use(Vuex) const store = new Vuex.Store({ state: { id: 'id', serverInfo:{//服务信息 networkFlag:'内网', serverURLInt:'http://192.168.11.251:10054',//服务器体检 10.0.1.104:10054 serverURL:'http://localhost:10054',//本地调试地址 //serverAPI:'http://78566b00.r1.cpolar.top/api',//外网地址 serverAPI:'http://192.168.0.94:8008/api', //内网地址 //serverAPI:'http://localhost:5106/api',//本地调试地址 } }, mutations: { test(state,id){ state.id = id; } }, getters:{ currentColor(state){ return state.colorList[state.colorIndex] } }, actions: { // lazy loading openid } }) export default store