Building in Production -> put to the Server
give an error: Vuex handler functions must not be anonymous. Resolve: npm cache clean --force npm install npm i npm@latest -g
This commit is contained in:
@@ -12,14 +12,11 @@ const state: IGlobalState = {
|
||||
}
|
||||
|
||||
const b = storeBuilder.module<IGlobalState>('GlobalModule', state)
|
||||
const stateGetter = b.state()
|
||||
|
||||
// Getters
|
||||
namespace Getters {
|
||||
|
||||
const conta = b.read(function conta(state): number {
|
||||
return state.conta
|
||||
})
|
||||
const conta = b.read(state => state.conta , 'conta')
|
||||
|
||||
export const getters = {
|
||||
get conta() {
|
||||
@@ -51,6 +48,8 @@ namespace Actions {
|
||||
|
||||
}
|
||||
|
||||
const stateGetter = b.state()
|
||||
|
||||
// Module
|
||||
const GlobalModule = {
|
||||
get state() { return stateGetter()},
|
||||
|
||||
Reference in New Issue
Block a user