diff --git a/.gitignore b/.gitignore index 0973f04542e..a06ef3d110f 100644 --- a/.gitignore +++ b/.gitignore @@ -75,11 +75,14 @@ jspm_packages/ .DS_Store .idea dist -_ts3.4 *.tsbuildinfo .watchmanconfig .rollup.cache +# the downlevel-dts output folders +_ts3.4 +_ts4.2 + # Files copied as part of the build packages/types/src/generated/**/*.ts diff --git a/package.json b/package.json index a031546d693..3f75a6f4cab 100644 --- a/package.json +++ b/package.json @@ -78,7 +78,7 @@ "cross-env": "^7.0.3", "cross-fetch": "^3.1.5", "cspell": "^6.0.0", - "downlevel-dts": ">=0.10.0", + "downlevel-dts": "^0.11.0", "eslint": "^8.15.0", "eslint-plugin-deprecation": "^1.3.2", "eslint-plugin-eslint-comments": "^3.2.0", diff --git a/packages/ast-spec/package.json b/packages/ast-spec/package.json index a6316be9c13..741b4ae0d27 100644 --- a/packages/ast-spec/package.json +++ b/packages/ast-spec/package.json @@ -31,7 +31,7 @@ "scripts": { "build": "tsc -b tsconfig.build.json && api-extractor run --local", "clean": "tsc -b tsconfig.build.json --clean", - "postclean": "rimraf dist && rimraf _ts3.4 && rimraf .rollup.cache && rimraf coverage", + "postclean": "rimraf dist && rimraf coverage", "clean-fixtures": "rimraf -g \"./src/**/fixtures/**/snapshots\"", "format": "prettier --write \"./**/*.{ts,mts,cts,tsx,js,mjs,cjs,jsx,json,md,css}\" --ignore-path ../../.prettierignore", "lint": "nx lint", diff --git a/packages/parser/package.json b/packages/parser/package.json index 13981a2feee..3cdc77f5f09 100644 --- a/packages/parser/package.json +++ b/packages/parser/package.json @@ -6,7 +6,7 @@ "types": "dist/index.d.ts", "files": [ "dist", - "_ts3.4", + "_ts4.2", "README.md", "LICENSE" ], @@ -33,9 +33,9 @@ ], "scripts": { "build": "tsc -b tsconfig.build.json", - "postbuild": "downlevel-dts dist _ts3.4/dist", + "postbuild": "downlevel-dts dist _ts4.2/dist --to=4.2", "clean": "tsc -b tsconfig.build.json --clean", - "postclean": "rimraf dist && rimraf _ts3.4 && rimraf coverage", + "postclean": "rimraf dist && rimraf _ts3.4 && rimraf _ts4.2 && rimraf coverage", "format": "prettier --write \"./**/*.{ts,mts,cts,tsx,js,mjs,cjs,jsx,json,md,css}\" --ignore-path ../../.prettierignore", "lint": "nx lint", "test": "jest --coverage", @@ -66,9 +66,9 @@ "url": "https://opencollective.com/typescript-eslint" }, "typesVersions": { - "<3.8": { + "<4.7": { "*": [ - "_ts3.4/*" + "_ts4.2/*" ] } } diff --git a/packages/scope-manager/package.json b/packages/scope-manager/package.json index b273be553b0..d427d18d5ff 100644 --- a/packages/scope-manager/package.json +++ b/packages/scope-manager/package.json @@ -57,9 +57,9 @@ "url": "https://opencollective.com/typescript-eslint" }, "typesVersions": { - "<3.8": { + "<4.7": { "*": [ - "_ts3.4/*" + "_ts4.2/*" ] } } diff --git a/packages/scope-manager/project.json b/packages/scope-manager/project.json index 9694ae86163..5d29f8634f4 100644 --- a/packages/scope-manager/project.json +++ b/packages/scope-manager/project.json @@ -6,14 +6,14 @@ "targets": { "build": { "executor": "nx:run-commands", - "outputs": ["{projectRoot}/dist", "{projectRoot}/_ts3.4"], + "outputs": ["{projectRoot}/dist", "{projectRoot}/_ts4.2"], "options": { "parallel": false, "cwd": "packages/scope-manager", "commands": [ - "rimraf _ts3.4", + "rimraf _ts4.2", "tsc -b tsconfig.build.json", - "downlevel-dts dist _ts3.4/dist" + "downlevel-dts dist _ts4.2/dist --to=4.2" ] } }, @@ -36,6 +36,7 @@ "commands": [ "tsc -b tsconfig.build.json --clean", "rimraf dist", + "rimraf _ts4.2", "rimraf _ts3.4", "rimraf coverage" ] diff --git a/packages/type-utils/package.json b/packages/type-utils/package.json index 1bb59c566f7..a8b583b7d9d 100644 --- a/packages/type-utils/package.json +++ b/packages/type-utils/package.json @@ -12,7 +12,7 @@ }, "files": [ "dist", - "_ts3.4", + "_ts4.2", "package.json", "README.md", "LICENSE" @@ -30,9 +30,9 @@ "types": "dist/index.d.ts", "scripts": { "build": "tsc -b tsconfig.build.json", - "postbuild": "downlevel-dts dist _ts3.4/dist", + "postbuild": "downlevel-dts dist _ts4.2/dist --to=4.2", "clean": "tsc -b tsconfig.build.json --clean", - "postclean": "rimraf dist && rimraf _ts3.4 && rimraf coverage", + "postclean": "rimraf dist && rimraf _ts3.4 && rimraf _ts4.2 && rimraf coverage", "format": "prettier --write \"./**/*.{ts,mts,cts,tsx,js,mjs,cjs,jsx,json,md,css}\" --ignore-path ../../.prettierignore", "lint": "nx lint", "test": "jest --coverage", @@ -61,9 +61,9 @@ "url": "https://opencollective.com/typescript-eslint" }, "typesVersions": { - "<3.8": { + "<4.7": { "*": [ - "_ts3.4/*" + "_ts4.2/*" ] } } diff --git a/packages/types/package.json b/packages/types/package.json index 003bfdd69ea..5103591ab95 100644 --- a/packages/types/package.json +++ b/packages/types/package.json @@ -12,7 +12,7 @@ }, "files": [ "dist", - "_ts3.4", + "_ts4.2", "package.json", "README.md", "LICENSE" @@ -31,9 +31,9 @@ "scripts": { "prebuild": "yarn tsx ./tools/copy-ast-spec.ts", "build": "tsc -b tsconfig.build.json", - "postbuild": "downlevel-dts dist _ts3.4/dist", + "postbuild": "downlevel-dts dist _ts4.2/dist --to=4.2", "clean": "tsc -b tsconfig.build.json --clean", - "postclean": "rimraf dist && rimraf src/generated && rimraf _ts3.4 && rimraf coverage", + "postclean": "rimraf dist && rimraf src/generated && rimraf _ts3.4 && rimraf _ts4.2 && rimraf coverage", "format": "prettier --write \"./**/*.{ts,mts,cts,tsx,js,mjs,cjs,jsx,json,md,css}\" --ignore-path ../../.prettierignore", "generate:lib": "yarn tsx ../scope-manager/tools/generate-lib.ts", "lint": "nx lint", @@ -71,9 +71,9 @@ "url": "https://opencollective.com/typescript-eslint" }, "typesVersions": { - "<3.8": { + "<4.7": { "*": [ - "_ts3.4/*" + "_ts4.2/*" ] } }, diff --git a/packages/typescript-estree/package.json b/packages/typescript-estree/package.json index 4414257fee6..99465452fbc 100644 --- a/packages/typescript-estree/package.json +++ b/packages/typescript-estree/package.json @@ -6,7 +6,7 @@ "types": "dist/index.d.ts", "files": [ "dist", - "_ts3.4", + "_ts4.2", "README.md", "LICENSE" ], @@ -33,9 +33,9 @@ ], "scripts": { "build": "tsc -b tsconfig.build.json", - "postbuild": "downlevel-dts dist _ts3.4/dist", + "postbuild": "downlevel-dts dist _ts4.2/dist --to=4.2", "clean": "tsc -b tsconfig.build.json --clean", - "postclean": "rimraf dist && rimraf _ts3.4 && rimraf coverage", + "postclean": "rimraf dist && rimraf _ts3.4 && rimraf _ts4.2 && rimraf coverage", "format": "prettier --write \"./**/*.{ts,mts,cts,tsx,js,mjs,cjs,jsx,json,md,css}\" --ignore-path ../../.prettierignore", "lint": "nx lint", "test": "jest --coverage", @@ -75,9 +75,9 @@ "url": "https://opencollective.com/typescript-eslint" }, "typesVersions": { - "<3.8": { + "<4.7": { "*": [ - "_ts3.4/*" + "_ts4.2/*" ] } } diff --git a/packages/utils/package.json b/packages/utils/package.json index 03834aa07a3..a1bb5059594 100644 --- a/packages/utils/package.json +++ b/packages/utils/package.json @@ -12,7 +12,7 @@ }, "files": [ "dist", - "_ts3.4", + "_ts4.2", "package.json", "README.md", "LICENSE" @@ -30,9 +30,9 @@ "types": "dist/index.d.ts", "scripts": { "build": "tsc -b tsconfig.build.json", - "postbuild": "downlevel-dts dist _ts3.4/dist", + "postbuild": "downlevel-dts dist _ts4.2/dist --to=4.2", "clean": "tsc -b tsconfig.build.json --clean", - "postclean": "rimraf dist && rimraf _ts3.4 && rimraf coverage", + "postclean": "rimraf dist && rimraf _ts3.4 && rimraf _ts4.2 && rimraf coverage", "format": "prettier --write \"./**/*.{ts,mts,cts,tsx,js,mjs,cjs,jsx,json,md,css}\" --ignore-path ../../.prettierignore", "lint": "nx lint", "test": "jest --coverage", @@ -60,9 +60,9 @@ "url": "https://opencollective.com/typescript-eslint" }, "typesVersions": { - "<3.8": { + "<4.7": { "*": [ - "_ts3.4/*" + "_ts4.2/*" ] } } diff --git a/packages/visitor-keys/package.json b/packages/visitor-keys/package.json index d4e7a2f0f16..6eb181ac620 100644 --- a/packages/visitor-keys/package.json +++ b/packages/visitor-keys/package.json @@ -12,7 +12,7 @@ }, "files": [ "dist", - "_ts3.4", + "_ts4.2", "package.json", "README.md", "LICENSE" @@ -30,9 +30,9 @@ "types": "dist/index.d.ts", "scripts": { "build": "tsc -b tsconfig.build.json", - "postbuild": "downlevel-dts dist _ts3.4/dist", + "postbuild": "downlevel-dts dist _ts4.2/dist --to=4.2", "clean": "tsc -b tsconfig.build.json --clean", - "postclean": "rimraf dist && rimraf _ts3.4 && rimraf coverage", + "postclean": "rimraf dist && rimraf _ts3.4 && rimraf _ts4.2 && rimraf coverage", "format": "prettier --write \"./**/*.{ts,mts,cts,tsx,js,mjs,cjs,jsx,json,md,css}\" --ignore-path ../../.prettierignore", "lint": "nx lint", "test": "jest --coverage", @@ -50,9 +50,9 @@ "url": "https://opencollective.com/typescript-eslint" }, "typesVersions": { - "<3.8": { + "<4.7": { "*": [ - "_ts3.4/*" + "_ts4.2/*" ] } } diff --git a/yarn.lock b/yarn.lock index 4ab54a03fc5..013601dd9cc 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4343,6 +4343,61 @@ dependencies: "@types/yargs-parser" "*" +"@typescript-eslint/experimental-utils@^5.0.0": + version "5.52.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/experimental-utils/-/experimental-utils-5.52.0.tgz#cc79b91ea62f43bb5e9bec2d94a7df513220e9df" + integrity sha512-kd8CRr04mNE3hw4et6+0T0NI5vli2H6dJCGzjX1r12s/FXUehLVadmvo2Nl3DN80YqAh1cVC6zYZAkpmGiVJ5g== + dependencies: + "@typescript-eslint/utils" "5.52.0" + +"@typescript-eslint/scope-manager@5.52.0": + version "5.52.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-5.52.0.tgz#a993d89a0556ea16811db48eabd7c5b72dcb83d1" + integrity sha512-AR7sxxfBKiNV0FWBSARxM8DmNxrwgnYMPwmpkC1Pl1n+eT8/I2NAUPuwDy/FmDcC6F8pBfmOcaxcxRHspgOBMw== + dependencies: + "@typescript-eslint/types" "5.52.0" + "@typescript-eslint/visitor-keys" "5.52.0" + +"@typescript-eslint/types@5.52.0": + version "5.52.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.52.0.tgz#19e9abc6afb5bd37a1a9bea877a1a836c0b3241b" + integrity sha512-oV7XU4CHYfBhk78fS7tkum+/Dpgsfi91IIDy7fjCyq2k6KB63M6gMC0YIvy+iABzmXThCRI6xpCEyVObBdWSDQ== + +"@typescript-eslint/typescript-estree@5.52.0": + version "5.52.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.52.0.tgz#6408cb3c2ccc01c03c278cb201cf07e73347dfca" + integrity sha512-WeWnjanyEwt6+fVrSR0MYgEpUAuROxuAH516WPjUblIrClzYJj0kBbjdnbQXLpgAN8qbEuGywiQsXUVDiAoEuQ== + dependencies: + "@typescript-eslint/types" "5.52.0" + "@typescript-eslint/visitor-keys" "5.52.0" + debug "^4.3.4" + globby "^11.1.0" + is-glob "^4.0.3" + semver "^7.3.7" + tsutils "^3.21.0" + +"@typescript-eslint/utils@5.52.0": + version "5.52.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.52.0.tgz#b260bb5a8f6b00a0ed51db66bdba4ed5e4845a72" + integrity sha512-As3lChhrbwWQLNk2HC8Ree96hldKIqk98EYvypd3It8Q1f8d5zWyIoaZEp2va5667M4ZyE7X8UUR+azXrFl+NA== + dependencies: + "@types/json-schema" "^7.0.9" + "@types/semver" "^7.3.12" + "@typescript-eslint/scope-manager" "5.52.0" + "@typescript-eslint/types" "5.52.0" + "@typescript-eslint/typescript-estree" "5.52.0" + eslint-scope "^5.1.1" + eslint-utils "^3.0.0" + semver "^7.3.7" + +"@typescript-eslint/visitor-keys@5.52.0": + version "5.52.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-5.52.0.tgz#e38c971259f44f80cfe49d97dbffa38e3e75030f" + integrity sha512-qMwpw6SU5VHCPr99y274xhbm+PRViK/NATY6qzt+Et7+mThGuFSl/ompj2/hrBlRP/kq+BFdgagnOSgw9TB0eA== + dependencies: + "@typescript-eslint/types" "5.52.0" + eslint-visitor-keys "^3.3.0" + "@webassemblyjs/ast@1.11.1": version "1.11.1" resolved "https://registry.yarnpkg.com/@webassemblyjs/ast/-/ast-1.11.1.tgz#2bfd767eae1a6996f432ff7e8d7fc75679c0b6a7" @@ -6638,10 +6693,10 @@ dotenv@~10.0.0: resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-10.0.0.tgz#3d4227b8fb95f81096cdd2b66653fb2c7085ba81" integrity sha512-rlBi9d8jpv9Sf1klPjNfFAuWDjKLwTIJJ/VxtoTwIR6hnZxcEOQCZg2oIL3MWBYw5GpUDKOEnND7LXTbIpQ03Q== -downlevel-dts@>=0.10.0: - version "0.10.0" - resolved "https://registry.yarnpkg.com/downlevel-dts/-/downlevel-dts-0.10.0.tgz#d2be7b4408a1f9eb3a39e15a361f8ea4f175facc" - integrity sha512-AZ7tnUy4XJArsjv6Bcuivvxx+weMvOGHF6seu7e7PVOqMDHMSlfgMl1kt+F4Y2+5TmDwKWHOdimM1DZKihQs8Q== +downlevel-dts@^0.11.0: + version "0.11.0" + resolved "https://registry.yarnpkg.com/downlevel-dts/-/downlevel-dts-0.11.0.tgz#514a2d723009c5845730c1db6c994484c596ed9c" + integrity sha512-vo835pntK7kzYStk7xUHDifiYJvXxVhUapt85uk2AI94gUUAQX9HNRtrcMHNSc3YHJUEHGbYIGsM99uIbgAtxw== dependencies: semver "^7.3.2" shelljs "^0.8.3"