import Store from 'herculex';
import actions from './actions/index';
import state from '../store/state';
import mutations from '../store/mutations';
import getters from '../store/getters';

export default new Store({
  connectGlobal: true,
  state,
  getters,
  mutations,
  actions: {
    async init({ dispatch }, payload) {
      await dispatch('start', payload);
    },
    ...actions,
  },
});

