vue中安装recorderx v-emoji-picker vue-context-menu vue-dragging失败的解决方法
Posted 秋9
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了vue中安装recorderx v-emoji-picker vue-context-menu vue-dragging失败的解决方法相关的知识,希望对你有一定的参考价值。
【现象】
98% after emitting CopyPlugin
ERROR Failed to compile with 16 errors17:16:04
These dependencies were not found:
* diff in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/views/create-ques/create-ques-check-out.vue?vue&type=script&lang=js&, ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/views/create-ques/create-ques-check.vue?vue&type=script&lang=js& and 4 others
* pdfjs-dist/es5/build/pdf.js in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./node_modules/vue-pdf/src/vuePdfNoSss.vue?vue&type=script&lang=js&
* worker-loader!pdfjs-dist/es5/build/pdf.worker.js in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./node_modules/vue-pdf/src/vuePdfNoSss.vue?vue&type=script&lang=js&
* pdfjs-dist/es5/web/pdf_viewer in ./node_modules/vue-pdf/src/pdfjsWrapper.js
* recorderx in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/ChatInterface/components/enterBox.vue?vue&type=script&lang=js&, ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/views/create-ques/create-ques-analysis-study.vue?vue&type=script&lang=js& and 1 other
* v-emoji-picker in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/ChatInterface/components/tools.vue?vue&type=script&lang=js&, ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/ChatInterface/components/enterBox.vue?vue&type=script&lang=js&
* vue-context-menu in ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/views/create-ques/create-ques-analysis-study.vue?vue&type=script&lang=js&
* vue-dragging in ./src/main.js
To install them, you can run: npm install --save diff pdfjs-dist/es5/build/pdf.js worker-loader!pdfjs-dist/es5/build/pdf.worker.js pdfjs-dist/es5/web/pdf_viewer recorderx v-emoji-picker vue-context-menu vue-dragging
【解决方法】
更换为淘宝数据源,具体操作如下:
npm install -g --registry=https://registry.npm.taobao.org
为了方便开发,我们最好是直接永久使用淘宝的镜像源
直接命令行的设置
$ npm config set registry https://registry.npm.taobao.org
手动修改设置
1.打开.npmrc文件(C:\\Program Files\\nodejs\\node_modules\\npm\\npmrc,没有的话可以使用git命令行建一个( touch .npmrc),用cmd命令建会报错)
2.增加 registry =https://registry.npm.taobao.org 即可。
如果需要恢复成原来的官方地址只需要执行如下命令:
npm config set registry https://registry.npmjs.org
检测是否安装成功:
npm config get registry
以上是关于vue中安装recorderx v-emoji-picker vue-context-menu vue-dragging失败的解决方法的主要内容,如果未能解决你的问题,请参考以下文章