问题描述:
npm install 安装项目依赖的时候,有时会出现:
ERR! Unexpected end of JSON input while parsing near 错误
原因:
npm 的包的缓存问题导致
解决:
npm cache clean --force //清除缓存
原因:package-lock.json文件版本号问题
解决:删除package-lock.json文件
npm install 安装项目依赖,报错ERR! Unexpected end of JSON input while parsing near的方法汇总
原文:https://www.cnblogs.com/wangweizhang/p/10643759.html