cnpm安裝報錯以及快速解決方法

1.使用npm install的時候報這個錯

npm WARN deprecated [email protected]: babili has been renamed to babel-minify. Please update to babel-preset-minify
npm WARN deprecated [email protected]: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools.
WARNING: You are likely using a version of node-tar or npm that is incompatible with this version of Node.js.
Please use either the version of npm that is bundled with Node.js, or a version of npm (> 5.5.1 or < 5.4.0) or node-tar (> 4.0.1) that is compatible with Node.js 9 and above.
npm[17388]: c:\ws\src\node_zlib.cc:460: Assertion `args.Length() == 7 && "init(windowBits, level, memLevel, strategy, writeResult, writeCallback," " dictionary)"' failed.
 1: 00007FF76A46F04A v8::internal::GCIdleTimeHandler::GCIdleTimeHandler+5114
 2: 00007FF76A44A0C6 node::MakeCallback+4518
 3: 00007FF76A44A17F node::MakeCallback+4703
 4: 00007FF76A3AF179 v8::internal::LookupIterator::index+93209
 5: 00007FF76AC4C122 v8::internal::OptimizingCompileDispatcher::Unblock+59890
 6: 00007FF76AC4D5AD v8::internal::OptimizingCompileDispatcher::Unblock+65149
 7: 00007FF76AC4C606 v8::internal::OptimizingCompileDispatcher::Unblock+61142
 8: 00007FF76AC4C4EB v8::internal::OptimizingCompileDispatcher::Unblock+60859
 9: 000002DB650DC5C1
2.使用cnpm命令時又報錯

TypeError: The value "false" is invalid for option "readableHighWaterMark"

3.最後拷貝nodejs的zip文件,刪除原來的文件,將zip包解壓覆蓋之前安裝的nodejs。然後重新安裝cnpm,使用cnpm install即解決上面同時出現的問題。

 

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章