mirror of https://github.com/Requarks/wiki.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
24 lines
534 B
24 lines
534 B
import Vue from 'vue'
|
|
import Vuex from 'vuex'
|
|
|
|
import navigator from './modules/navigator'
|
|
|
|
Vue.use(Vuex)
|
|
|
|
export default new Vuex.Store({
|
|
state: {
|
|
loading: false
|
|
},
|
|
mutations: {
|
|
loadingChange: (state, loadingState) => { state.loading = loadingState }
|
|
},
|
|
actions: {
|
|
alert({ dispatch }, opts) { dispatch('navigator/alert', opts) },
|
|
startLoading({ commit }) { commit('loadingChange', true) },
|
|
stopLoading({ commit }) { commit('loadingChange', false) }
|
|
},
|
|
getters: {},
|
|
modules: {
|
|
navigator
|
|
}
|
|
})
|