chore: update packages and replace builder
PR Checklist
Please check if your PR fulfills the following requirements:
- [x] The commit message follows our guidelines: CONTRIBUTING.md#commit
- [ ] Tests for the changes have been added (for bug fixes / features)
- [ ] Docs have been added / updated (for bug fixes / features)
PR Type
What kind of change does this PR introduce?
[ ] Bugfix
[ ] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[x] Build related changes
[ ] CI related changes
[ ] Documentation content changes
[ ] Other... Please describe:
What is the current behavior?
The lumberjack repo was using Angular version 11 and the old ngpackgr builder @angular-devkit/build-ng-packagr:build.
Issue Number: N/A
What is the new behavior?
The Lumberjack repo is using the latest version of Angular (12.2.x) and the new ngpackgr builder @angular-devkit/build-angular:ng-packagr
Does this PR introduce a breaking change?
[ ] Yes
[x] No
Other information
This PR depends on https://github.com/ngworker/angular-versions-action/pull/35 and https://github.com/ngworker/angular-versions-action/pull/36
error @angular-builders/[email protected]: The engine "node" is incompatible with this module. Expected version ">=12.14.1". Got "10.24.1"
Solution: Downgrade Jest to 26.x and the Jest builder to 11.x when testing older versions of Angular with Node.js 10.x.
Looking at angular-cli-diff, we should also change compilerOptions.target from "es2015" to "es2017" in tsconfig.json.
error @angular-builders/[email protected]: The engine "node" is incompatible with this module. Expected version ">=12.14.1". Got "10.24.1"Solution: Downgrade Jest to 26.x and the Jest builder to 11.x when testing older versions of Angular with Node.js 10.x.
I had to explicitly upgrade because I was having other problems with version 26 after the upgrade.
However, do we need to run our test in Node 10?? Can not we just perform the build using the different versions of Node but everything else (dev-related) could be done with the latest Node??
@NachoVazquez
However, do we need to run our test in Node 10?? Can not we just perform the build using the different versions of Node but everything else (dev-related) could be done with the latest Node??
We must be able to test using Node.js 10.x with certain versions of Angular. That's what some our consumers will be using since Angular supports this version.
@all-contributors please add @patelvimal for code
@NachoVazquez Angular 11 doesn't support Node.js 16.x, see https://gist.github.com/LayZeeDK/c822cc812f75bb07b7c55d07ba2719b3
@NachoVazquez Angular 11 doesn't support Node.js 14.x, see https://gist.github.com/LayZeeDK/c822cc812f75bb07b7c55d07ba2719b3







