2.0.0-alpha.0 • Published 4 years ago

@yzfe/vuex-helper v2.0.0-alpha.0

Weekly downloads
1
License
MIT
Repository
-
Last release
4 years ago

vuex 的辅助函数

 主要是  写 getter, mutation, action 的时候可以提供类型  推导

使用

import { getter, mutation, action, decorator } from '@app/vuex-helper'

/*** state ***/
let state = {
    name: 'Allenice'
}

/*** getters ***/
let getters = getter(state, {})

/*** mutations ***/
let mutations = mutation(state, {})

/*** actions ***/
let actions = action(state, {})

/*** module store ***/
let store = {
    namespaced: true,
    state,
    getters,
    mutations,
    actions
}
2.0.0-alpha.0

4 years ago

1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago