由于CircularJSON,Angular CLI 7新项目失败

cra*_*den 10 npm angular-cli angular

刚刚将Angular CLI重新安装到版本7.1.1.运行时ng new project-name,会发生以下错误:

npm WARN deprecated circular-json@0.5.9: CircularJSON is in maintenance only, flatted is its successor.
npm ERR! code ERR_STREAM_WRITE_AFTER_END npm ERR! write after end
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\[username]\AppData\Roaming\npm-cache\_logs\2018-12-04T20_40_23_399Z-debug.log
Package install failed, see above.

更改为项目目录时,无法提供新的Angular应用程序.怎么修这个呢?

nir*_*aft 7

您应该查看错误详细信息。

npm WARN deprecated circular-json@0.5.9: CircularJSON is in maintenance 
only, flatted is its successor.
Run Code Online (Sandbox Code Playgroud)

据此,不推荐使用circular-json@0.5.9。您应该使用flatted。直接来自CircularJSON创建者的超轻量级(0.5K)和快速循环JSON解析器。CircularJSON的未来称为扁平化。

更小,更快,并能生产平均减小的输出太,分层是新的,bloatless,ESM和CJS兼容,圆形JSON解析器。

使用以下命令安装: npm i flatted