Skip to content

Commit

Permalink
chore(v2): minimum supported node version is now v14 (#17036)
Browse files Browse the repository at this point in the history
This is the current active LTS version and is a good minimum requirement.

Re-introduction of #11964. Fixes #16438


----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
  • Loading branch information
rix0rrr committed Oct 18, 2021
1 parent 30f4584 commit d0a27c1
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions .yarnrc
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@
# be forced to registry.yarnpkg.com.
# https://github.com/npm/cli/issues/3783
registry "https://registry.npmjs.org"
ignore-engines true # the 'engines' key for 'aws-cdk-lib' has specifies node14 as min while v1 will remain at node10
6 changes: 5 additions & 1 deletion tools/@aws-cdk/pkglint/lib/rules.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1129,7 +1129,11 @@ export class MustHaveNodeEnginesDeclaration extends ValidationRule {
public readonly name = 'package-info/engines';

public validate(pkg: PackageJson): void {
expectJSON(this.name, pkg, 'engines.node', '>= 10.13.0 <13 || >=13.7.0');
if (cdkMajorVersion() === 2) {
expectJSON(this.name, pkg, 'engines.node', '>= 14.15.0');
} else {
expectJSON(this.name, pkg, 'engines.node', '>= 10.13.0 <13 || >=13.7.0');
}
}
}

Expand Down

0 comments on commit d0a27c1

Please sign in to comment.