1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
import tagsView from './tagsView';
import sidebar from './sidebar';
import base from './base/base';
import { FETCH_START, FETCH_DONE } from './mutation-types';
const state = () => ({
loading: false,
});
const getters = {
loading: state => state.loading,
};
const actions = {
fetchStart({ commit }) {
commit(FETCH_START);
},
fetchDone({ commit }) {
commit(FETCH_DONE);
},
};
const mutations = {
[FETCH_START](state) {
state.loading = true;
},
[FETCH_DONE](state) {
state.loading = false;
},
};
export default {
modules: {
tagsView,
sidebar,
base,
},
state,
getters,
actions,
mutations,
};