Skip to content

Commit

Permalink
chore: align @types/node with node version
Browse files Browse the repository at this point in the history
Align @types/node with the version of node that is used in the repo. Add
a comment to update @types/node when the node version in the repo is
bumped.

Prevent npm-check-updates and Dependabot from bumping @types/node major
versions.
  • Loading branch information
matijs committed Oct 29, 2024
1 parent 04c10f8 commit 152894b
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 4 deletions.
4 changes: 4 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ updates:
update-types:
- "patch"
- "minor"
ignore:
- dependency-name: "@types/node"
update-types:
- "version-update:semver-major"
versioning-strategy: "increase-if-necessary"
open-pull-requests-limit: 20
reviewers:
Expand Down
9 changes: 8 additions & 1 deletion .ncurc.major.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,13 @@ const minorConfig = require('./.ncurc.minor.cjs');

module.exports = {
...minorConfig,
reject: [...minorConfig.reject, 'eslint', 'eslint-plugin-json', 'style-dictionary'],
reject: [
...minorConfig.reject,
// @types/node is kept in line with the node version in .nvmrc and package.json#engines.node
'@types/node',
'eslint',
'eslint-plugin-json',
'style-dictionary',
],
target: 'latest',
};
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
},
"packageManager": "[email protected]+sha512.22721b3a11f81661ae1ec68ce1a7b879425a1ca5b991c975b074ac220b187ce56c708fe5db69f4c962c989452eee76c82877f4ee80f474cebd61ee13461b6228",
"engines": {
"//": "Update @types/node when updating this node version",
"node": "^20",
"pnpm": "^9"
},
Expand All @@ -23,7 +24,7 @@
],
"devDependencies": {
"@changesets/cli": "2.27.8",
"@types/node": "22.5.5",
"@types/node": "20.14.13",
"@typescript-eslint/eslint-plugin": "8.6.0",
"@typescript-eslint/parser": "8.6.0",
"eslint": "8.57.1",
Expand Down
4 changes: 2 additions & 2 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 152894b

Please sign in to comment.