Skip to content

Commit 105f8f7

Browse files
Update dependencies (#6)
* build(deps): upgrade packages to minor and patch versions Steps: - Use the `ncu` command (`npm-check-updates`) to check the version of the packages to update: Checking fusionauth-quickstart-javascript-angular-web/complete-application/package.json [====================] 23/23 100% karma ~6.4.0 → ~6.4.2 karma-chrome-launcher ~3.1.0 → ~3.2.0 karma-coverage ~2.2.0 → ~2.2.1 karma-jasmine-html-reporter ~2.0.0 → ~2.1.0 rxjs ~7.5.0 → ~7.8.1 tslib ^2.3.0 → ^2.6.2 References: - https://www.npmjs.com/package/npm-check-updates - #4 * build(deps): upgrade packages to major versions Steps: - Use the `ng update @angular/cli@^16 @angular/core@^16` command to update from one major version to another. References: - https://angular.io/cli/update - #4 * build(deps): upgrade packages to minor and patch versions Steps: - Use the `ncu` command (`npm-check-updates`) to check the version of the packages to update: Checking fusionauth-quickstart-javascript-angular-web/complete-application/package.json [====================] 23/23 100% typescript ~5.1.6 → ~5.2.2 References: - https://www.npmjs.com/package/npm-check-updates - #4 * Revert "build(deps): upgrade packages to minor and patch versions" Error: - Found errors in the terminal when run the `npm install` npm ERR! Could not resolve dependency: npm ERR! peer typescript@">=4.9.3 <5.2" from @angular-devkit/build-angular@16.2.5 Reason: - The `ERESOLVE` error from npm is indicating that there is a conflict with the project dependencies. The main problem here seems to be a conflict between the version of `typescript` you have installed and what `@angular-devkit/build-angular` expects. In short, `@angular-devkit/build-angular@16.2.5` expects a `typescript` version between `>=4.9.3` and `<5.2`, but you currently have `5.2.2` version of `typescript` installed. Solution: - Downgrade TypeScript to 5.1.6 instead use 5.2.2 Other possible solutions: - I would recommend trying these solutions in the order they are presented, as the first option is the safest. The option to use `--legacy-peer-deps` should be your last resort, as it may lead to unexpected problems later on. 1. **Downgrade TypeScript**: If you don't have a specific reason for using TypeScript 5.2.2, you can downgrade to resolve the conflict: ````bash npm install typescript@5.1.6 --save-dev ``` This will install ``5.1.6` version of TypeScript, which is compatible with `@angular-devkit/build-angular@16.2.5`. 2. **Use Flag `--legacy-peer-deps`**: If you do not want to change the version of TypeScript and are willing to risk incompatibilities, you can use the `--legacy-peer-deps` flag: ````bash npm install --legacy-peer-deps ``` However, be careful when doing this. While it may resolve the error and allow you to install the dependencies, you could face runtime problems due to incompatibilities. 3. **Update `@angular-devkit/build-angular`** (if a newer version is available): There may be a newer version of `@angular-devkit/build-angular` that is compatible with TypeScript 5.2.2. You can try upgrading: ````bash npm install @angular-devkit/build-angular@latest --save-dev ``` Then, check if the problem is solved. 4. **Check your `peerDependencies`**: If the project was cloned from a repository or is a previous project, it is possible that the `peerDependencies` in your `package.json` are causing the conflict. In that case, check and adjust the versions in the `package.json` to make sure they are compatible. References: - #4 - This reverts commit 9e6f851.
1 parent c6be4d5 commit 105f8f7

2 files changed

Lines changed: 2363 additions & 2269 deletions

File tree

0 commit comments

Comments
 (0)