在SVN上拉下来一个vue项目,上面没有提交项目里面的node_modules文件夹,所以要自己执行 npm install 安装,但安装完后运行项目后却报错了:

$ npm run dev

> poverty@1.0.0 dev F:\05 poverty alleviation project\poverty-git
> webpack-dev-server --inline --progress --config build/webpack.dev.conf.js
。。。。。此处省略加载的进度。。。。。
94% asset optimization ERROR Failed to compile with 7 errors15:16:02

//中间部分都是同下面的一种错误
error in ./src/assets/css/home/dataProfile.scss Module build failed: Error: ENOENT: no such file or directory, scandir 'F:\05 poverty alleviation project\poverty-git\node_modules\node-sass\vendor'
at Object.fs.readdirSync (fs.js:904:18)
at Object.getInstalledBinaries (F:\05 poverty alleviation project\poverty-git\node_modules\node-sass\lib\extensions.js:129:13)
at foundBinariesList (F:\05 poverty alleviation project\poverty-git\node_modules\node-sass\lib\errors.js:20:15)
at foundBinaries (F:\05 poverty alleviation project\poverty-git\node_modules\node-sass\lib\errors.js:15:5)
at Object.module.exports.missingBinary (F:\05 poverty alleviation project\poverty-git\node_modules\node-sass\lib\errors.js:45:5)
at module.exports (F:\05 poverty alleviation project\poverty-git\node_modules\node-sass\lib\binding.js:15:30)
at Object.<anonymous> (F:\05 poverty alleviation project\poverty-git\node_modules\node-sass\lib\index.js:14:35)
at Module._compile (module.js:643:30)
at Object.Module._extensions..js (module.js:654:10)
at Module.load (module.js:556:32)
at tryModuleLoad (module.js:499:12)
at Function.Module._load (module.js:491:3)
at Module.require (module.js:587:17)
at require (internal/module.js:11:18)
at Object.sassLoader (F:\05 poverty alleviation project\poverty-git\node_modules\sass-loader\lib\loader.js:24:22) @ ./src/assets/css/home/dataProfile.scss 4:14-222 13:3-17:5 14:22-230
@ ./node_modules/babel-loader/lib!./node_modules/vue-loader/lib/selector.js?type=script&index=0!./node_modules/iview-loader??ref--0-1!./src/pages/home/dataProfile.vue
@ ./src/pages/home/dataProfile.vue
@ ./src/router/routers.js
@ ./src/router/index.js
@ ./src/main.js
@ multi (webpack)-dev-server/client?http://localhost:8080 webpack/hot/dev-server ./src/main.js

考虑是没有把需要的插件或者包都安装下来,所以就重新执行了一次 npm install ,然后根据报错信息,重新安装ajv(没见过这玩意,这个是什么呢?)

$ npm install
npm WARN ajv-keywords@3.2.0 requires a peer of ajv@^6.0.0 but none is installed. You must install peer dependencies yourself. audited 33495 packages in 10.919s
found 16 vulnerabilities (1 low, 10 moderate, 4 high, 1 critical)
run `npm audit fix` to fix them, or `npm audit` for details $ npm install ajv@^6.0.0
+ ajv@6.5.2
added 6 packages from 1 contributor, updated 3 packages and audited 33501 packages in 14.673s
found 16 vulnerabilities (1 low, 10 moderate, 4 high, 1 critical)
run `npm audit fix` to fix them, or `npm audit` for details

然后下一步重新执行 npm run dev 就可以运行代码了。

下载一个vue项目执行npm install 后运行项目npm run dev后出错 - 问题解决的更多相关文章

  1. nodejs+express工程 在npm install之后或使用npm install bootstrap命令安装bootstrap之后

    nodejs+express工程 在npm install之后或使用npm install bootstrap命令安装bootstrap之后引入bootstrap文件 如果你的静态资源存放在多个目录下 ...

  2. 执行npm install报错:npm ERR! code EINTEGRITY

    命令行执行npm install报错如下: D:\frontend\viewsdev>npm install npm ERR! code EINTEGRITY npm ERR! sha512-8 ...

  3. php项目执行composer install时报错

    报错信息: Loading composer repositories with package informationInstalling dependencies (including requi ...

  4. npm install xxx --save-dev 与npm install xxx --save 的区别

    正常情况下: 当你为你的模块安装一个依赖模块时 1.你得先安装他们(在模块根目录下npm install module-name) 2.连同版本号手动将他们添加到模块配置文件package.json中 ...

  5. npm install 报错(npm ERR! errno -4048,Error: EPERM: operation not permitted,)解决方法

    npm ERR! path E:\SouthernPowerGridProject\web_project\AutoOPS\autoops\node_modules\fsevents\node_mod ...

  6. npm install报错类似于npm WARN tar ENOENT: no such file or directory, open '***\node_modules\.staging\***

    报错类似于如下图 解决方法: 删除文件 package-lock.json,再重新执行npm i或者npm install

  7. webpack run dev后并没有生成dist目录,但是浏览器里却读取了dist里的build.js?

    最近想看看现在做的React项目用的脚手架,看了下webpack的配置,尝试修改一些东西看看输出结果,结果允许npm run dev发现没有输出目录,怎么回事呢.又安装了vue官方提供的webpack ...

  8. 【maven 报错】maven项目执行maven install时报错Error assembling WAR: webxml attribute is required (or pre-existing WEB-INF/web.xml if executing in update mode)

    在使用maven新建的web项目中,执行 执行如上的这两个操作,报错: [ERROR] Failed to execute goal org.apache.maven.plugins:maven-co ...

  9. eclipse升级Android SDK Tool版本到25.2.5后运行项目报错Unable to build: the file dx.jar was not loaded from the SDK folder

    概述 由于最近通过SDK-Manager更新了build-tools,当要用到dx.jar这个包时,自动调用最新版本Android SDK build-tools中dx.jar,但是运行android ...

随机推荐

  1. js 数组去重的三种方法(unique)

    方法一: Array.prototype.unique=function(){ var arr=[];//新建一个临时数组 for(var i=0;i<this.length;i++){//遍历 ...

  2. tomcat 时间相差8个小时,百度上查到的,备份下

    通常网上一查都是 修改 tomcat 的参数 ,如catalina 文件,jvm parameters 等.如果都不起作用,可以使用如下方式.. 你可以修改jdk的时间校正了,你这么来.进入 \hom ...

  3. 针对程序员的podcast

    身为程序员们,必须要懂得合理的利用琐碎时间来提炼自身,或许上下班途中或骑行或徒步或...时,以下这些Podcasts对你有些许作用: The Hanselminutes podcast by Scot ...

  4. 自然语言处理--中文文本向量化counterVectorizer()

    1.载入文档 #!/usr/bin/python # -*- coding: utf-8 -*- import pandas as pd import re import jieba from skl ...

  5. 实体类在set字段时报空指针异常

    实体类在set字段时报空指针异常的原因: T_Entry entry=null;entry.setGeneName("1212");entry.setEntryName(" ...

  6. Leed code 11. Container With Most Water

    public int maxArea(int[] height) { int left = 0, right = height.length - 1; int maxArea = 0; while ( ...

  7. 201709021工作日记--CAS解读

    CAS主要参考博文:classtag  http://www.jianshu.com/p/473e14d5ab2d CAS(Compare and swap)比较和替换是设计并发算法时用到的一种技术 ...

  8. ROS教程

    Learning ROS 学习ROS Depending on your learning style and preferences, you can take two approaches to ...

  9. hdu3853 LOOPS(概率dp) 2016-05-26 17:37 89人阅读 评论(0) 收藏

    LOOPS Time Limit: 15000/5000 MS (Java/Others)    Memory Limit: 125536/65536 K (Java/Others) Total Su ...

  10. java中如何通过Class获取类的属性、方法、注释

    public static String getPKName(Class clazz) { Field[] fields = clazz.getDeclaredFields(); for (Field ...