Javascript 未捕获的SyntaxError:使用vuex时无效或意外的令牌

Javascript 未捕获的SyntaxError:使用vuex时无效或意外的令牌,javascript,vue.js,vuejs2,vue-component,vuex,Javascript,Vue.js,Vuejs2,Vue Component,Vuex,这是我的商店档案 const store = new Vuex.Store({ state: { pokemons: [] }, actions: { LOAD_POKEMON_LIST: function() { axios.get('http://pokeapi.co/api/v2/pokemon/').then((response) => { console.log(response.data) }, (err)

这是我的商店档案

const store = new Vuex.Store({
state: {
    pokemons: []
},
actions: {
    LOAD_POKEMON_LIST: function() {
        axios.get('http://pokeapi.co/api/v2/pokemon/').then((response) => {
            console.log(response.data)
        }, (err) => {
            console.log(err)
        })
    }
}
});

export default store
编译文件时,我的浏览器会抛出此错误

Uncaught SyntaxError: Invalid or unexpected token

当我在本地机器上运行此代码时,它不会给我任何错误。我也不会得到任何错误。这是完整的代码吗?是的,这是完整的代码