page-loader.js 333 B

123456789101112131415
  1. export default {
  2. namespaced: true,
  3. state: {
  4. shown: true,
  5. msg: 'Loading...'
  6. },
  7. getters: {},
  8. mutations: {
  9. shownChange: (state, shownState) => { state.shown = shownState },
  10. msgChange: (state, newText) => { state.msg = newText }
  11. },
  12. actions: {
  13. complete({ commit }) { commit('shownChange', false) }
  14. }
  15. }