我正在尝试从角度10升级到11。当我运行下面的命令时,我会得到一个错误。
ng更新“角/核心”11角/cli@11
The installed local Angular CLI version is older than the latest stable version.
Installing a temporary version to perform the update.
Installing packages for tooling via npm.
Installed packages for tooling via npm.
Using package manager: 'npm'
Collecting installed dependencies...
Found 44 dependencies.
Fetching dependency metadata from registry...
Package "@angular-devkit/build-angular" has an incompatible peer dependency to
"typescript" (requires "~4.0.0 || ~4.1.0", would install "4.3.5")
Package "@angular/compiler-cli" has an incompatible peer dependency to "typescript" (requires ">=4.0 <4.2", would install "4.3.5")
× Migration failed: Incompatible peer dependencies found.
Peer dependency warnings when installing dependencies means that those dependencies might not work correctly together.
You can use the '--force' option to ignore incompatible peer dependencies and instead address these warnings later.
See "C:\Users\DEFAUL~1.DES\AppData\Local\Temp\ng-13szno\angular-errors.log" for further details.我不知道这是什么错误。我查看了package.json文件,并且已经有了类型记录4.3.5。
发布于 2022-11-24 07:27:19
理想的方法是先解决依赖关系,然后再使用迁移命令。在某些情况下,yarn install有助于更清楚地理解依赖关系。
https://stackoverflow.com/questions/68367692
复制相似问题