Skip to content

Commit c14d522

Browse files
committed
Merge branch 'main' into 'lib/es2015/fix-array-unscopables'
1 parent cf62705 commit c14d522

File tree

9,605 files changed

+1694214
-1328636
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

9,605 files changed

+1694214
-1328636
lines changed

.devcontainer/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44
ARG VARIANT="14-buster"
55
FROM mcr.microsoft.com/vscode/devcontainers/javascript-node:0-${VARIANT}
66

7-
RUN sudo -u node npm install -g gulp-cli
7+
RUN sudo -u node npm install -g hereby

.dockerignore

Lines changed: 0 additions & 47 deletions
This file was deleted.

.eslintignore

Lines changed: 0 additions & 9 deletions
This file was deleted.

.eslintplugin.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ const fs = require("fs");
22
const path = require("path");
33

44
const rulesDir = path.join(__dirname, "scripts", "eslint", "rules");
5-
const ext = ".js";
5+
const ext = ".cjs";
66
const ruleFiles = fs.readdirSync(rulesDir).filter((p) => p.endsWith(ext));
77

88
module.exports = {

.eslintrc.json

Lines changed: 60 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
{
2+
"root": true,
23
"parser": "@typescript-eslint/parser",
34
"parserOptions": {
45
"warnOnUnsupportedTypeScriptVersion": false,
5-
"ecmaVersion": 6,
66
"sourceType": "module"
77
},
88
"env": {
@@ -11,22 +11,26 @@
1111
"es6": true
1212
},
1313
"plugins": [
14-
"@typescript-eslint", "jsdoc", "no-null", "import", "eslint-plugin-local"
14+
"@typescript-eslint", "no-null", "import", "eslint-plugin-local", "simple-import-sort"
1515
],
16-
"overrides": [
17-
// By default, the ESLint CLI only looks at .js files. But, it will also look at
18-
// any files which are referenced in an override config. Most users of typescript-eslint
19-
// get this behavior by default by extending a recommended typescript-eslint config, which
20-
// just so happens to override some core ESLint rules. We don't extend from any config, so
21-
// explicitly reference TS files here so the CLI picks them up.
22-
//
23-
// ESLint in VS Code will lint any opened file (so long as it's not eslintignore'd), so
24-
// that will work regardless of the below.
25-
{ "files": ["*.ts"] }
16+
"ignorePatterns": [
17+
"**/node_modules/**",
18+
"/built/**",
19+
"/tests/**",
20+
"/lib/**",
21+
"/src/lib/*.generated.d.ts",
22+
"/scripts/**/*.js",
23+
"/scripts/**/*.d.*",
24+
"/internal/**",
25+
"/coverage/**"
2626
],
2727
"rules": {
28+
"simple-import-sort/imports": "error",
29+
"simple-import-sort/exports": "error",
30+
2831
"@typescript-eslint/adjacent-overload-signatures": "error",
2932
"@typescript-eslint/array-type": "error",
33+
"@typescript-eslint/no-array-constructor": "error",
3034

3135
"brace-style": "off",
3236
"@typescript-eslint/brace-style": ["error", "stroustrup", { "allowSingleLine": true }],
@@ -62,12 +66,14 @@
6266
"@typescript-eslint/prefer-for-of": "error",
6367
"@typescript-eslint/prefer-function-type": "error",
6468
"@typescript-eslint/prefer-namespace-keyword": "error",
69+
"@typescript-eslint/prefer-as-const": "error",
6570

6671
"quotes": "off",
6772
"@typescript-eslint/quotes": ["error", "double", { "avoidEscape": true, "allowTemplateLiterals": true }],
6873

6974
"semi": "off",
7075
"@typescript-eslint/semi": "error",
76+
"@typescript-eslint/no-extra-semi": "error",
7177

7278
"space-before-function-paren": "off",
7379
"@typescript-eslint/space-before-function-paren": ["error", {
@@ -80,6 +86,8 @@
8086
"@typescript-eslint/type-annotation-spacing": "error",
8187
"@typescript-eslint/unified-signatures": "error",
8288

89+
"@typescript-eslint/no-extra-non-null-assertion": "error",
90+
8391
// scripts/eslint/rules
8492
"local/object-literal-surrounding-space": "error",
8593
"local/no-type-assertion-whitespace": "error",
@@ -94,17 +102,14 @@
94102
"local/simple-indent": "error",
95103
"local/debug-assert": "error",
96104
"local/no-keywords": "error",
97-
"local/one-namespace-per-file": "error",
105+
"local/jsdoc-format": "error",
98106

99107
// eslint-plugin-import
100108
"import/no-extraneous-dependencies": ["error", { "optionalDependencies": false }],
101109

102110
// eslint-plugin-no-null
103111
"no-null/no-null": "error",
104112

105-
// eslint-plugin-jsdoc
106-
"jsdoc/check-alignment": "error",
107-
108113
// eslint
109114
"constructor-super": "error",
110115
"curly": ["error", "multi-line"],
@@ -143,6 +148,43 @@
143148
"quote-props": ["error", "consistent-as-needed"],
144149
"space-in-parens": "error",
145150
"unicode-bom": ["error", "never"],
146-
"use-isnan": "error"
147-
}
151+
"use-isnan": "error",
152+
"no-prototype-builtins": "error",
153+
"no-self-assign": "error",
154+
"no-dupe-else-if": "error"
155+
},
156+
"overrides": [
157+
// By default, the ESLint CLI only looks at .js files. But, it will also look at
158+
// any files which are referenced in an override config. Most users of typescript-eslint
159+
// get this behavior by default by extending a recommended typescript-eslint config, which
160+
// just so happens to override some core ESLint rules. We don't extend from any config, so
161+
// explicitly reference TS files here so the CLI picks them up.
162+
//
163+
// ESLint in VS Code will lint any opened file (so long as it's not eslintignore'd), so
164+
// that will work regardless of the below.
165+
//
166+
// The same applies to mjs files; ESLint appears to not scan those either.
167+
{ "files": ["*.ts", "*.mts", "*.cts", "*.mjs", "*.cjs"] },
168+
{
169+
"files": ["*.mjs", "*.mts"],
170+
"rules": {
171+
// These globals don't exist outside of CJS files.
172+
"no-restricted-globals": ["error",
173+
{ "name": "__filename" },
174+
{ "name": "__dirname" },
175+
{ "name": "require" },
176+
{ "name": "module" },
177+
{ "name": "exports" }
178+
]
179+
}
180+
},
181+
{
182+
// These files contain imports in a specific order that are generally unsafe to modify.
183+
"files": ["**/_namespaces/**"],
184+
"rules": {
185+
"simple-import-sort/imports": "off",
186+
"simple-import-sort/exports": "off"
187+
}
188+
}
189+
]
148190
}

.git-blame-ignore-revs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# Generated module conversion step - inlineImports
2+
07758c08ab72481885e662c98d67a0e3a071b032
3+
# Generated module conversion step - stripNamespaces
4+
b6c053882696af8ddd94a600429f30584d303d7f
5+
# Generated module conversion step - explicitify
6+
9a0b85ce2a3f85f498ab2c05474b4c0b96b111c9
7+
# Generated module conversion step - unindent
8+
94724a8c2e68a4c7e267072ca79971f317c45e4a

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
*.js linguist-language=TypeScript
2+
**/*.json linguist-language=jsonc
23
* -text
Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
11
name : CodeQL Configuration
22

33
paths:
4-
- './src'
4+
- src
5+
- scripts
6+
- Herebyfile.mjs
7+
paths-ignore:
8+
- src/lib

0 commit comments

Comments
 (0)