From e6235bf61b781066653581b57b7cd976c9c4f905 Mon Sep 17 00:00:00 2001 From: Brad Zacher Date: Mon, 15 May 2023 10:32:41 +0800 Subject: [PATCH] feat: drop support for node v14 and test against node v20 (#7022) --- .github/workflows/ci.yml | 4 ++-- docs/linting/Typed_Linting.mdx | 2 +- package.json | 2 +- packages/ast-spec/package.json | 2 +- packages/eslint-plugin-tslint/package.json | 2 +- packages/eslint-plugin/package.json | 2 +- packages/parser/package.json | 2 +- packages/rule-schema-to-typescript-types/package.json | 2 +- packages/rule-tester/package.json | 2 +- packages/scope-manager/package.json | 2 +- packages/type-utils/package.json | 2 +- packages/types/package.json | 2 +- packages/typescript-estree/package.json | 2 +- packages/utils/package.json | 2 +- packages/visitor-keys/package.json | 2 +- packages/website-eslint/package.json | 2 +- .../blog/2023-03-13-announcing-typescript-eslint-v6-beta.md | 1 + 17 files changed, 18 insertions(+), 17 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a56c40f207c..5fd02228fe0 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,7 +11,7 @@ on: merge_group: env: - PRIMARY_NODE_VERSION: 18 + PRIMARY_NODE_VERSION: 20 # Only set the read-write token if we are on the main branch NX_CLOUD_ACCESS_TOKEN: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/main') && secrets.NX_CLOUD_ACCESS_TOKEN || '' }} @@ -136,7 +136,7 @@ jobs: strategy: matrix: # just run on the oldest and latest supported versions and assume the intermediate versions are good - node-version: [14, 18] + node-version: [16, 20] package: [ 'ast-spec', diff --git a/docs/linting/Typed_Linting.mdx b/docs/linting/Typed_Linting.mdx index 1592fc23cba..5f778f73292 100644 --- a/docs/linting/Typed_Linting.mdx +++ b/docs/linting/Typed_Linting.mdx @@ -34,7 +34,7 @@ See [our TSConfig inclusion FAQ](./Troubleshooting.mdx#i-get-errors-telling-me-e In more detail: -- `plugin:@typescript-eslint/recommended-type-checked` is another [recommended configuration](./CONFIGURATIONS.mdx) we provide. This one contains recommended rules that additionally require type information. +- `plugin:@typescript-eslint/recommended-type-checked` is another [recommended configuration](./Configurations.mdx) we provide. This one contains recommended rules that additionally require type information. - `parserOptions.project` tells our parser how to find the TSConfig for each source file (`true` indicates to find the closest `tsconfig.json` for each source file) - If your project is a multi-package monorepo, see [our docs on configuring a monorepo](./typed-linting/Monorepos.mdx). - `parserOptions.tsconfigRootDir` tells our parser the absolute path of your project's root directory (see [Parser#tsconfigRootDir](../architecture/Parser.mdx#tsconfigRootDir)). diff --git a/package.json b/package.json index fbb75edf7a0..78d9b2be6ff 100644 --- a/package.json +++ b/package.json @@ -50,7 +50,7 @@ "typecheck": "nx run-many --target=typecheck --parallel" }, "engines": { - "node": "^14.18.0 || ^16.0.0 || >=18.0.0" + "node": "^16.0.0 || >=18.0.0" }, "devDependencies": { "@babel/code-frame": "^7.21.4", diff --git a/packages/ast-spec/package.json b/packages/ast-spec/package.json index 2ba1b20d65f..299b87a06f8 100644 --- a/packages/ast-spec/package.json +++ b/packages/ast-spec/package.json @@ -9,7 +9,7 @@ "estree" ], "engines": { - "node": "^14.18.0 || ^16.0.0 || >=18.0.0" + "node": "^16.0.0 || >=18.0.0" }, "files": [ "dist", diff --git a/packages/eslint-plugin-tslint/package.json b/packages/eslint-plugin-tslint/package.json index 2ba3f7487ae..217dacde67d 100644 --- a/packages/eslint-plugin-tslint/package.json +++ b/packages/eslint-plugin-tslint/package.json @@ -19,7 +19,7 @@ "./package.json": "./package.json" }, "engines": { - "node": "^14.18.0 || ^16.0.0 || >=18.0.0" + "node": "^16.0.0 || >=18.0.0" }, "repository": { "type": "git", diff --git a/packages/eslint-plugin/package.json b/packages/eslint-plugin/package.json index 05c898b3d3a..b65a51b4c88 100644 --- a/packages/eslint-plugin/package.json +++ b/packages/eslint-plugin/package.json @@ -23,7 +23,7 @@ } }, "engines": { - "node": "^14.18.0 || ^16.0.0 || >=18.0.0" + "node": "^16.0.0 || >=18.0.0" }, "repository": { "type": "git", diff --git a/packages/parser/package.json b/packages/parser/package.json index 7559b99f288..bc5deb80e18 100644 --- a/packages/parser/package.json +++ b/packages/parser/package.json @@ -17,7 +17,7 @@ "./package.json": "./package.json" }, "engines": { - "node": "^14.18.0 || ^16.0.0 || >=18.0.0" + "node": "^16.0.0 || >=18.0.0" }, "repository": { "type": "git", diff --git a/packages/rule-schema-to-typescript-types/package.json b/packages/rule-schema-to-typescript-types/package.json index 1e65907fcf3..efd09bef5fb 100644 --- a/packages/rule-schema-to-typescript-types/package.json +++ b/packages/rule-schema-to-typescript-types/package.json @@ -11,7 +11,7 @@ "./package.json": "./package.json" }, "engines": { - "node": "^14.18.0 || ^16.0.0 || >=18.0.0" + "node": "^16.0.0 || >=18.0.0" }, "repository": { "type": "git", diff --git a/packages/rule-tester/package.json b/packages/rule-tester/package.json index 8e8c04ea93c..678f5456bed 100644 --- a/packages/rule-tester/package.json +++ b/packages/rule-tester/package.json @@ -17,7 +17,7 @@ "./package.json": "./package.json" }, "engines": { - "node": "^14.18.0 || ^16.0.0 || >=18.0.0" + "node": "^16.0.0 || >=18.0.0" }, "repository": { "type": "git", diff --git a/packages/scope-manager/package.json b/packages/scope-manager/package.json index 12a3c3318d8..3455f61e51c 100644 --- a/packages/scope-manager/package.json +++ b/packages/scope-manager/package.json @@ -17,7 +17,7 @@ "./package.json": "./package.json" }, "engines": { - "node": "^14.18.0 || ^16.0.0 || >=18.0.0" + "node": "^16.0.0 || >=18.0.0" }, "repository": { "type": "git", diff --git a/packages/type-utils/package.json b/packages/type-utils/package.json index 6423f7ca5f8..a0ccbd65e94 100644 --- a/packages/type-utils/package.json +++ b/packages/type-utils/package.json @@ -18,7 +18,7 @@ "./package.json": "./package.json" }, "engines": { - "node": "^14.18.0 || ^16.0.0 || >=18.0.0" + "node": "^16.0.0 || >=18.0.0" }, "repository": { "type": "git", diff --git a/packages/types/package.json b/packages/types/package.json index 4da28b857c8..7e86184e064 100644 --- a/packages/types/package.json +++ b/packages/types/package.json @@ -18,7 +18,7 @@ "./package.json": "./package.json" }, "engines": { - "node": "^14.18.0 || ^16.0.0 || >=18.0.0" + "node": "^16.0.0 || >=18.0.0" }, "repository": { "type": "git", diff --git a/packages/typescript-estree/package.json b/packages/typescript-estree/package.json index f437ae5d575..294aba5273d 100644 --- a/packages/typescript-estree/package.json +++ b/packages/typescript-estree/package.json @@ -21,7 +21,7 @@ } }, "engines": { - "node": "^14.18.0 || ^16.0.0 || >=18.0.0" + "node": "^16.0.0 || >=18.0.0" }, "repository": { "type": "git", diff --git a/packages/utils/package.json b/packages/utils/package.json index 2692e811fe2..4fab1c35225 100644 --- a/packages/utils/package.json +++ b/packages/utils/package.json @@ -38,7 +38,7 @@ "./package.json": "./package.json" }, "engines": { - "node": "^14.18.0 || ^16.0.0 || >=18.0.0" + "node": "^16.0.0 || >=18.0.0" }, "repository": { "type": "git", diff --git a/packages/visitor-keys/package.json b/packages/visitor-keys/package.json index bf26cc33972..1c58c47e503 100644 --- a/packages/visitor-keys/package.json +++ b/packages/visitor-keys/package.json @@ -18,7 +18,7 @@ "./package.json": "./package.json" }, "engines": { - "node": "^14.18.0 || ^16.0.0 || >=18.0.0" + "node": "^16.0.0 || >=18.0.0" }, "repository": { "type": "git", diff --git a/packages/website-eslint/package.json b/packages/website-eslint/package.json index ad119de4ec6..ccf98c255ed 100644 --- a/packages/website-eslint/package.json +++ b/packages/website-eslint/package.json @@ -14,7 +14,7 @@ } }, "engines": { - "node": "^14.18.0 || ^16.0.0 || >=18.0.0" + "node": "^16.0.0 || >=18.0.0" }, "scripts": { "build": "yarn tsx ./build.ts", diff --git a/packages/website/blog/2023-03-13-announcing-typescript-eslint-v6-beta.md b/packages/website/blog/2023-03-13-announcing-typescript-eslint-v6-beta.md index d2236bc9e84..615a99907dd 100644 --- a/packages/website/blog/2023-03-13-announcing-typescript-eslint-v6-beta.md +++ b/packages/website/blog/2023-03-13-announcing-typescript-eslint-v6-beta.md @@ -162,6 +162,7 @@ Several rules were changed in significant enough ways to be considered breaking - [feat(typescript-estree): deprecate createDefaultProgram](https://github.com/typescript-eslint/typescript-eslint/pull/5890): Renames `createDefaultProgram` to `deprecated__createDefaultProgram`, with associated `@deprecated` TSDoc tags and warnings. - [feat: drop support for node v12](https://github.com/typescript-eslint/typescript-eslint/pull/5918) +- [feat: drop support for node v14](https://github.com/typescript-eslint/typescript-eslint/pull/7022) - [feat: bump minimum supported TS version to 4.3.5](https://github.com/typescript-eslint/typescript-eslint/issues/6923): this matches [DefinitelyTyped's 2-year support window](https://github.com/DefinitelyTyped/DefinitelyTyped#support-window). - [chore: drop support for ESLint v6](https://github.com/typescript-eslint/typescript-eslint/pull/5972) - [feat(eslint-plugin): [prefer-readonly-parameter-types] added an optional type allowlist](https://github.com/typescript-eslint/typescript-eslint/pull/4436): changes the public `isTypeReadonlyArrayOrTuple` function's first argument from a `checker: ts.TypeChecker` to a full `program: ts.Program`