Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

npm 引入报错 #140

Closed
zhongmax opened this issue Mar 17, 2021 · 0 comments
Closed

npm 引入报错 #140

zhongmax opened this issue Mar 17, 2021 · 0 comments

Comments

@zhongmax
Copy link

"dependencies": {
    "ajv": "^7.2.1",
    "axios": "^0.18.0",
    "echarts": "^4.9.0",
    "element-ui": "^2.3.7",
    "js-cookie": "^2.2.0",
    "normalize.css": "^8.0.0",
    "nprogress": "^0.2.0",
    "v-distpicker": "^1.0.20",
    "ve-charts": "^0.9.5",
    "vue": "^2.5.2",
    "vue-router": "^3.0.1",
    "vuex": "^3.0.1"
  },

在 main.js 中,引入后,npm run dev 报错

import VeCharts from 've-charts'
Vue.use(VeCharts)

错误信息

ERROR  Failed to compile with 1 errors                                                         上午9:28:58

 error  in ./node_modules/ve-charts/lib/ve-charts.umd.min.js

Module parse failed: Unexpected token (8:48734)
You may need an appropriate loader to handle this file type.
|  * license : MIT
|  * http://adamwdraper.github.com/Numeral-js/
|  */(function(i,o){n=o,a="function"===typeof n?n.call(t,r,t,e):n,void 0===a||(e.exports=a)})(0,(function(){var e,t,r="2.0.6",n={},a={},i={currentLocale:............
@ ./src/main.js 8:0-33
 @ multi (webpack)-dev-server/client?http://localhost:9001 webpack/hot/dev-server ./src/main.js

因为对npm不太熟悉,不太清楚是什么问题

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant