跟往常一样运行npm install 的时候,突然报错。错误情况如下:

npm ERR! Cannot read property 'match' of undefined

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\user\AppData\Roaming\npm-cache\_logs\2018-08-06T01_49_46_486Z-debug.log

查找了很多的方法,有人说清楚npm本地缓存(npm cache clear --force),我都试过了,还是报错。。
最后删了项目文件夹下面的package-lock.json,然后再运行npm install便可正常的安装了~~~

如果还是不行的话,那就一条条执行下面这四条命令吧~~~

 rm -rf node_modules
rm package-lock.json
npm cache clear --force
npm install

npm ERR! Cannot read property 'match' of undefined 错误处理的更多相关文章

  1. npm ERR! Cannot read property 'match' of undefined

    在Vue项目中运行npm i命令时直接提示npm ERR! Cannot read property 'match' of undefined错误了,此时需要把package-lock.json文件删 ...

  2. npm ERR! Cannot read property 'resolve' of undefined

    一 .有可能是版本过低,或者软件损坏,重新安装一下试试 地址

  3. npm ERR! Cannot read property 'path' of null

    npm错误: 错误信息如下: $ sudo npm install -g bean-sdk sudo: npm: command not found $ npm install -g bean-sdk ...

  4. [转载][jQuery] Cannot read property ‘msie’ of undefined错误的解决方法

    参考 [jQuery] Cannot read property ‘msie’ of undefined错误的解决方法 ---------------------------------------- ...

  5. [jQuery] Cannot read property ‘msie’ of undefined错误的解决方法 --转

    初用Yii的srbac模块.出现 Cannot read property ‘msie’ of undefined 错误.上网查询,找到如下的文章.使用文末的打补丁的方法,成功搞定.感谢. ===== ...

  6. [jQuery1.9]Cannot read property ‘msie’ of undefined错误的解决方法

    原文:[jQuery1.9]Cannot read property 'msie' of undefined错误的解决方法 $.browser在jQuery1.9里被删除了,所以项目的js代码里用到$ ...

  7. [jQuery] Cannot read property ‘msie’ of undefined错误的解决方法

    最近把一个项目的jQuery升级到最新版,发现有些页面报错Cannot read property ‘msie’ of undefined.上jQuery网站上搜了一下,原因是$.browser这个a ...

  8. jquery升级到新版本报错[jQuery] Cannot read property ‘msie’ of undefined错误的解决方法(转)

    最近把一个项目的jQuery升级到最新版,发现有些页面报错Cannot read property 'msie' of undefined.上jQuery网站上搜了一下,原因是$.browser这个a ...

  9. 关于百度地图(离线)使用过程报“Cannot read property 'jb' of undefined ”错误的解决办法

    使用百度地图(离线)API时,地图无法显示,f12查看报错: BaiduApi_2.0.js:1056 Uncaught TypeError: Cannot read property 'jb' of ...

随机推荐

  1. Python爬虫-- selenium库

    selenium库 selenium 是一套完整的web应用程序测试系统,包含了测试的录制(selenium IDE),编写及运行(Selenium Remote Control)和测试的并行处理(S ...

  2. Linux安装mariadb详细步骤

    1.安装mariadb yum和源码编译安装的区别? 1.路径区别-yum安装的软件是他自定义的,源码安装的软件./configure --preifx=软件安装的绝对路径 2.yum仓库的软件,版本 ...

  3. 我的Android进阶之旅------>如何在多个LinearLayout中添加分隔线

    如果要适合于所有的Android版本,可以在多个LinearLayout放置用于显示分隔线的View.例如,放一个ImageView组件,然后将其背景设为分隔线的颜色或图像,分隔线View的定义代码如 ...

  4. c#中多线程写DataGridView出现滚动栏导致程序卡死(无响应)的解决的方法

    版权声明:本文为博主原创文章,未经博主同意不得转载. https://blog.csdn.net/u013529927/article/details/24225567 由于写的程序涉及到多线程维护一 ...

  5. session,cookie的理解(总结)

    会话(Session)跟踪是Web程序中常用的技术,用来跟踪用户的整个会话.常用的会话跟踪技术是Cookie与Session.Cookie通过在客户端记录信息确定用户身份,Session通过在服务器端 ...

  6. Java for LeetCode 106 Construct Binary Tree from Inorder and Postorder Traversal

    Construct Binary Tree from Inorder and Postorder Traversal Total Accepted: 31041 Total Submissions: ...

  7. HDU2825 Wireless Password —— AC自动机 + 状压DP

    题目链接:https://vjudge.net/problem/HDU-2825 Wireless Password Time Limit: 2000/1000 MS (Java/Others)    ...

  8. Spring Boot2.0之整合JSP

    首先不建议整合JSP哈,spring boot 对jsp的支持力度不大.  内置tomcat不支持jsp. 注意:在创建项目时候一定是war类型的,而不是跟之前那个freemarker那种jar类型. ...

  9. zabbix 报表

    摘自: https://www.w3cschool.cn/zabbix_manager/zabbix_manager-z45f1zie.html

  10. frp支持httpIP地址加端口号访问

    (一)安装就不再多说 传送门:https://blog.csdn.net/superljn/article/details/81289993 (二)vim frps.ini [common] bind ...