Npm ./node_modules/Vuex/dist/Vuex.esm.js中的警告
我正在测试的项目工作正常,但在我的项目上运行npm run dev后,我收到以下警告消息:Npm ./node_modules/Vuex/dist/Vuex.esm.js中的警告,npm,visual-studio-code,vuejs2,vuex,Npm,Visual Studio Code,Vuejs2,Vuex,我正在测试的项目工作正常,但在我的项目上运行npm run dev后,我收到以下警告消息: WARNING Compiled with 1 warnings 17:06:47 warning in ./node_m
WARNING Compiled with 1 warnings 17:06:47
warning in ./node_modules/Vuex/dist/vuex.esm.js
There are multiple modules with names that only differ in casing.
This can lead to unexpected behavior when compiling on a filesystem with other case-semantic.
Use equal casing. Compare these module identifiers:
* /Users/me/code/vue/vuex-test/node_modules/Vuex/dist/vuex.esm.js
Used by 1 module(s), i. e.
/Users/me/code/vue/vuex-test/node_modules/babel-loader/lib/index.js!/Users/me/code/vue/vuex-test/node_modules/vue-loader/lib/selector.js?type=script&index=0!/Users/me/code/vue/vuex-test/src/components/Test.vue
* /Users/me/code/vue/vuex-test/node_modules/vuex/dist/vuex.esm.js
Used by 1 module(s), i. e.
/Users/me/code/vue/vuex-test/node_modules/babel-loader/lib/index.js!/Users/me/code/vue/vuex-test/src/store/store.js
这是由my./store/store.js文件中的import-store-from'Vuex'行引起的,该行由my main.js中的import-store-from./store/store'调用
这是Vuex模块中的错误,还是我可以在代码中修复它?行:
import Vuex from 'vuex'
应写明:
import Vuex from 'Vuex'
我也遇到过类似的问题。我已经停止了应用程序,并使用npm run dev重新启动了它,错误消失了。 我在用
import Vuex from 'vuex';
但这似乎不是问题