2.0.0-alpha.0 • Published 3 years ago

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

Weekly downloads
1
License
MIT
Repository
-
Last release
3 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

3 years ago

1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago