'首次提交'

This commit is contained in:
有来技术
2021-11-13 23:26:02 +08:00
commit 232db25546
21 changed files with 1448 additions and 0 deletions

25
src/store/index.ts Normal file
View File

@@ -0,0 +1,25 @@
import {InjectionKey} from 'vue'
import {createStore, Store} from 'vuex'
export interface State {
count: number
}
export const key: InjectionKey<Store<State>> = Symbol()
export const store = createStore<State>({
state() {
return {
count: 0
}
},
mutations: {
increment(state: { count: number }) {
state.count++
}
}
})