Skip to content

Instantly share code, notes, and snippets.

@kasvith
Created March 10, 2018 15:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kasvith/3c50869333bf49ea18365f7354078226 to your computer and use it in GitHub Desktop.
Save kasvith/3c50869333bf49ea18365f7354078226 to your computer and use it in GitHub Desktop.
'use strict'
import Vue from 'vue'
import Vuex from 'vuex'
Vue.use(Vuex)
export const store = new Vuex.Store({
state: {
layout: 'simple-layout'
},
mutations: {
SET_LAYOUT (state, payload) {
state.layout = payload
}
},
getters: {
layout (state) {
return state.layout
}
}
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment