美文网首页
cross-env vue的版本

cross-env vue的版本

作者: 9b559869875b | 来源:发表于2017-12-01 15:11 被阅读385次

    laravel 

    npm run dev 报错 spawn ENOENT

    方法:npm install cross-env

    继续报新的错误

    Vue packages version mismatch:

    - vue@2.4.4

    - vue-template-compiler@2.5.2

    This may cause things to work incorrectly. Make sure to use the same version for both.

    If you are using vue-loader@>=10.0, simply update vue-template-compiler.

    If you are using vue-loader@<10.0 or vueify, re-installing vue-loader/vueify should bump vue-template-compiler to the latest.

    方法:npm install vue-loader

    + vue-loader@13.3.0 会自动被加入package.json的dependencies

    npm install vue-template-compiler

    + vue-template-compiler@2.5.9 

    再跑npm run dev,看看有什么问题

    哎呀还是同样的错误

    把vue-template-compiler的版本改成和vue的版本一样

    "vue": "2.4.4"

    vue-template-compiler": "2.4.4"

    npm update vue-template-compiler

    终于可以了

    DONECompiled successfully in 11139ms22:33:23

    npm run dev:

    cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js

    相关文章

      网友评论

          本文标题:cross-env vue的版本

          本文链接:https://www.haomeiwen.com/subject/davbbxtx.html