Skip to content

Instantly share code, notes, and snippets.

@simonjcarr
Created August 10, 2020 18:52
Show Gist options
  • Select an option

  • Save simonjcarr/64dfb211a118cd9932d142d9f01da467 to your computer and use it in GitHub Desktop.

Select an option

Save simonjcarr/64dfb211a118cd9932d142d9f01da467 to your computer and use it in GitHub Desktop.
import Vue from "vue";
import Vuex from "vuex";
import Todo from './todo' //Import the todo module
import createPersistedState from 'vuex-persistedstate'
Vue.use(Vuex);
export default new Vuex.Store({
state: {},
mutations: {},
actions: {},
modules: {
Todo //Reference the Todo module
},
plugins: [createPersistedState()]
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment