Nuxt/examples/vuex-store-modules/store/articles/comments.js
2017-10-31 21:43:55 +08:00

20 lines
441 B
JavaScript

export const state = () => ({
list: [
'Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.',
'Lorem ipsum dolor sit amet, consetetur sadipscing elit.',
'Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.'
]
})
export const mutations = {
add(state, title) {
state.list.push(title)
}
}
export const getters = {
get(state) {
return state.list
}
}