在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. 启动多个eclipse 时,因为一个另一个启动报错,

    启动多个eclipse 时,因为一个另一个启动报错, 原因: 可能是 有一个 eclipse  中 的 tomcat  配置出错:preference中  tomcat 配置  context dec ...

  2. 移动文件流的读写指针---fseek

    函数原型:int fseek(FILE *stream,long offset,int origin) stream:文件指针, offset:偏移量,正数表示正向偏移,负数表示负向偏移.origin ...

  3. Core Dump 程序故障分析

    1.编写一个应用程序,使用gdb+core dump进行故障分析, core dump的概念: core dump又叫核心转存:当程序在运行过程中发生异常,这时Linux系统可以把程序在运行时的内存内 ...

  4. 【Log】logback的配置和使用(一)

    logback介绍 Logback是由log4j创始人设计的又一个开源日志组件.logback当前分成三个模块:logback-core,logback- classic和logback-access ...

  5. 2018.07.03 BZOJ 1007: [HNOI2008]水平可见直线(简单计算几何)

    1007: [HNOI2008]水平可见直线 Time Limit: 1 Sec Memory Limit: 162 MB Description 在xoy直角坐标平面上有n条直线L1,L2,-Ln, ...

  6. java多线程同步(转)

    原文地址:http://developer.51cto.com/art/201509/490965.htm 一.场景 因为当我们有多个线程要同时访问一个变量或对象时,如果这些线程中既有读又有写操作时, ...

  7. Java IO之字符流

    public static void main(String[] args) { FileWriter fw = null; try { fw = new FileWriter("/User ...

  8. linux week3

      2.如何快速的回到 上⼀一次所在的位置 cd An argument of - is equivalent to $OLDPWD.  cd -  #cd $OLDPWD cd - #快速的回到 上 ...

  9. UVa 210 Concurrency Simulator (双端队列+模拟)

    题意:给定n个程序,每种程序有五种操作,分别为 var = constant(赋值),print var (打印), lock, unlock,end. 变量用小写字母表示,初始化为0,为程序所公有( ...

  10. MySQL】存储过程、游标、循环简单实例

    create procedure my_procedure() -- 创建存储过程 begin -- 开始存储过程 declare my_id varchar(32); -- 自定义变量1 decla ...