执行命令node
ng update @angular/cli --migrate-only --from=1.7.1 npm install --save-dev @angular/cli@latest
注意from=1.7.1,填写本身的原version 而后可能由于包的缘由会有一些报错,根据报错内容,谷歌解决便可npm
Error: Local workspace file ('angular.json') could not be foundjson