今天碰到一个错误,如下:

Cannot destructure property `compile` of 'undefined' or 'null'

20 error code ELIFECYCLE
21 error errno 1
22 error demo@0.1.0 start: `node scripts/start.js`
22 error Exit status 1
23 error Failed at the demo@0.1.0 start script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 1, true ]
 

在网上找了几种方法,在这里汇总一下:

1:

Cleaning Cache and Node_module are not enough. Follow this steps:

  • npm cache clean --force
  • delete node_modules folder
  • delete package-lock.json file
  • npm install

2:修改node_modules文件夹权限

 

然鹅,都没有什么作用,还是回滚版本解决的,,,,,虽然治标不治本

Logo

腾讯云面向开发者汇聚海量精品云计算使用和开发经验,营造开放的云计算技术生态圈。

更多推荐