Nuxt/examples/middleware/store/index.js

13 lines
175 B
JavaScript
Raw Normal View History

2017-02-03 14:09:27 +00:00
export const state = {
visits: []
}
export const mutations = {
ADD_VISIT (state, path) {
state.visits.push({
path,
date: new Date().toJSON()
})
}
}