Started a store

This commit is contained in:
2019-11-16 21:04:00 +01:00
parent cb0d3633ac
commit 3680d9ba43
3 changed files with 35 additions and 2 deletions

View File

@@ -0,0 +1,21 @@
export default {
namespaced: true,
state: {
player: undefined
},
getters: {
player: (state) => {
return state.player;
}
},
mutations: {
SET_PLAYER: (state, player) => {
state.player = player;
}
},
actios: {
setPlayer({ commit }, player) {
commit('SET_PLAYER', player)
}
}
}