Skip to content

Commit 141b40b

Browse files
committed
Merge branch 'main' into babel-let-const
2 parents e67fbc0 + 72d4973 commit 141b40b

File tree

5,061 files changed

+551731
-144512
lines changed

Some content is hidden

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

5,061 files changed

+551731
-144512
lines changed

.c8rc.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44
"include": ["src/**", "built/local/**"],
55
"exclude": ["**/node_modules/**"],
66
"mergeAsync": true
7-
}
7+
}

.devcontainer/devcontainer.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,10 @@
1818
}
1919
},
2020
"extensions": [
21-
"dbaeumer.vscode-eslint"
21+
"dbaeumer.vscode-eslint",
22+
"dprint.dprint"
2223
]
2324
}
2425
},
2526
"remoteUser": "node"
26-
}
27+
}

.dprint.jsonc

+9-2
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@
3030
"importDeclaration.sortNamedImports": "maintain"
3131
},
3232
"prettier": {
33+
"newLineKind": "lf",
3334
"associations": [
3435
"**/*.{yaml,yml}"
3536
],
@@ -38,6 +39,10 @@
3839
"yml.singleQuote": true,
3940
"yaml.singleQuote": true
4041
},
42+
"json": {
43+
// This would be good to do in known-JSONC files, but VS Code warns on trailing commas.
44+
"trailingCommas": "never"
45+
},
4146
"excludes": [
4247
"**/node_modules",
4348
"**/*-lock.json",
@@ -49,8 +54,10 @@
4954
"**/*.generated.*",
5055
"scripts/*.d.*"
5156
],
57+
// Note: if adding new languages, make sure settings.template.json is updated too.
5258
"plugins": [
53-
"https://plugins.dprint.dev/typescript-0.86.1.wasm",
54-
"https://plugins.dprint.dev/prettier-0.27.0.json@3557a62b4507c55a47d8cde0683195b14d13c41dda66d0f0b0e111aed107e2fe"
59+
"https://plugins.dprint.dev/typescript-0.88.8.wasm",
60+
"https://plugins.dprint.dev/json-0.19.1.wasm",
61+
"https://plugins.dprint.dev/prettier-0.32.1.json@19aa403ef0862ba8c41164e3dc6f84c0b7a66c2b11e42726b23dd25e6302ada9"
5562
]
5663
}

.eslintrc.json

+8-4
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,10 @@
1616
"plugin:@typescript-eslint/stylistic"
1717
],
1818
"plugins": [
19-
"@typescript-eslint", "no-null", "eslint-plugin-local", "simple-import-sort"
19+
"@typescript-eslint",
20+
"no-null",
21+
"eslint-plugin-local",
22+
"simple-import-sort"
2023
],
2124
"ignorePatterns": [
2225
"**/node_modules/**",
@@ -113,7 +116,7 @@
113116
"local/only-arrow-functions": [
114117
"error",
115118
{
116-
"allowNamedFunctions": true ,
119+
"allowNamedFunctions": true,
117120
"allowDeclarations": true
118121
}
119122
],
@@ -133,7 +136,7 @@
133136
"overrides": [
134137
// By default, the ESLint CLI only looks at .js files. But, it will also look at
135138
// any files which are referenced in an override config. Most users of typescript-eslint
136-
// get this behavior by default by extending a recommended typescript-eslint config, which
139+
// get this behavior by default by extending a recommended typescript-eslint config, which
137140
// just so happens to override some core ESLint rules. We don't extend from any config, so
138141
// explicitly reference TS files here so the CLI picks them up.
139142
//
@@ -146,7 +149,8 @@
146149
"files": ["*.mjs", "*.mts"],
147150
"rules": {
148151
// These globals don't exist outside of CJS files.
149-
"no-restricted-globals": ["error",
152+
"no-restricted-globals": [
153+
"error",
150154
{ "name": "__filename" },
151155
{ "name": "__dirname" },
152156
{ "name": "require" },

.github/ISSUE_TEMPLATE/bug_report.yml

+8-10
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,7 @@ body:
1313
1414
List them here so people in the future can find this one more easily.
1515
placeholder: |
16-
List of keywords you searched for before creating this issue.
17-
Write them down here so that others can find this bug more easily and help provide feedback.
16+
List of keywords you searched for before creating this issue. Write them down here so that others can find this bug more easily and help provide feedback.
1817
1918
e.g. "function inference any", "jsx attribute spread", "move to file duplicate imports", "discriminated union inference", "ts2822"
2019
validations:
@@ -26,21 +25,19 @@ body:
2625
description: |
2726
When did you start seeing this bug occur?
2827
29-
"Bugs" that have existed in TS for a long time are very likely to be FAQs; refer to
30-
https://github.com/Microsoft/TypeScript/wiki/FAQ#common-bugs-that-arent-bugs
28+
"Bugs" that have existed in TS for a long time are very likely to be FAQs; please refer to the [FAQ wiki page](https://github.com/Microsoft/TypeScript/wiki/FAQ#common-bugs-that-arent-bugs).
3129
30+
Please try the nightly version of TS to see if it's already been fixed. Install `typescript@next` or use the [Playground](http://www.typescriptlang.org/play/?ts=Nightly).
3231
33-
If possible, please try testing the nightly version of TS to see if it's already been fixed. For npm: `typescript@next`
32+
If possible, try bisecting the issue using [every-ts](https://www.npmjs.com/package/every-ts#bisecting), which should narrow down the problem to a specific change.
3433
35-
This is also the 'Nightly' version in the playground: http://www.typescriptlang.org/play/?ts=Nightly
36-
37-
38-
Note: The TypeScript Playground can be used to try older versions of TypeScript.
34+
The Playground also supports versions of TypeScript back to TypeScript 3.3.
3935
4036
Please keep and fill in the line that best applies.
4137
value: |
4238
- This is a crash
4339
- This changed between versions ______ and _______
40+
- This changed in commit or PR _______
4441
- This is the behavior in every version I tried, and I reviewed the FAQ for entries about _________
4542
- I was unable to test this on prior versions because _______
4643
validations:
@@ -54,7 +51,6 @@ body:
5451
5552
This should have the same code as the code snippet below, and use whichever settings are relevant to your report.
5653
57-
5854
As a last resort, you can link to a repo, but these will be slower for us to investigate.
5955
placeholder: 'Playground link with relevant code: https://www.typescriptlang.org/play?#code/PTAEFkE9QYwewCYFNQHM5IM6gBZIE5JA'
6056
validations:
@@ -65,6 +61,7 @@ body:
6561
label: 💻 Code
6662
description: |
6763
Please post the relevant code sample here as well.
64+
6865
This code and the Playground code should be the same, do not use separate examples.
6966
7067
We can quickly address your report if:
@@ -74,6 +71,7 @@ body:
7471
- The incorrectness of the behavior is readily apparent from reading the sample.
7572
7673
Reports are slower to investigate if:
74+
7775
- We have to pare too much extraneous code.
7876
- We have to clone a large repo and validate that the problem isn't elsewhere.
7977
- The sample is confusing or doesn't clearly demonstrate what's wrong.

.github/ISSUE_TEMPLATE/config.yml

+15-15
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
1-
---
2-
blank_issues_enabled: false
3-
contact_links:
4-
- about: 'Please ask and answer usage questions on Stack Overflow.'
5-
name: Question
6-
url: 'https://stackoverflow.com/questions/tagged/typescript'
7-
- about: 'Alternatively, you can use the TypeScript Community Discord.'
8-
name: Chat
9-
url: 'https://discord.gg/typescript'
10-
- about: 'Please check the FAQ before filing new issues'
11-
name: 'TypeScript FAQ'
12-
url: 'https://github.com/microsoft/TypeScript/wiki/FAQ'
13-
- about: 'Please raise issues about the site on its own repo.'
14-
name: Website
15-
url: 'https://github.com/microsoft/TypeScript-Website/issues/new'
1+
---
2+
blank_issues_enabled: false
3+
contact_links:
4+
- about: 'Please ask and answer usage questions on Stack Overflow.'
5+
name: Question
6+
url: 'https://stackoverflow.com/questions/tagged/typescript'
7+
- about: 'Alternatively, you can use the TypeScript Community Discord.'
8+
name: Chat
9+
url: 'https://discord.gg/typescript'
10+
- about: 'Please check the FAQ before filing new issues'
11+
name: 'TypeScript FAQ'
12+
url: 'https://github.com/microsoft/TypeScript/wiki/FAQ'
13+
- about: 'Please raise issues about the site on its own repo.'
14+
name: Website
15+
url: 'https://github.com/microsoft/TypeScript-Website/issues/new'

.github/ISSUE_TEMPLATE/feature_request.yml

+5-7
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,7 @@ body:
1515
1616
The "Common Feature Requests" section of the FAQ lists many popular requests: https://github.com/Microsoft/TypeScript/wiki/FAQ#common-feature-requests
1717
placeholder: |
18-
List of keywords you searched for before creating this issue.
19-
Write them down here so that others can find this suggestion more easily and help provide feedback.
18+
List of keywords you searched for before creating this issue. Write them down here so that others can find this suggestion more easily and help provide feedback.
2019
2120
e.g. "isArray readonly", "regex string types", "json const assertion import"
2221
validations:
@@ -26,9 +25,7 @@ body:
2625
attributes:
2726
label: '✅ Viability Checklist'
2827
description: |
29-
Suggestions that don't meet all these criteria are very, very unlikely to be accepted.
30-
We always recommend reviewing the TypeScript design goals before investing time writing
31-
a proposal for ideas outside the scope of the project.
28+
Suggestions that don't meet all these criteria are very, very unlikely to be accepted. We always recommend reviewing the TypeScript design goals before investing time writing a proposal for ideas outside the scope of the project.
3229
3330
My suggestion meets the following guidelines.
3431
options:
@@ -40,6 +37,8 @@ body:
4037
required: true
4138
- label: This isn't a runtime feature (e.g. library functionality, non-ECMAScript syntax with JavaScript output, new syntax sugar for JS, etc.)
4239
required: true
40+
- label: "This isn't a request to add a new utility type: https://github.com/microsoft/TypeScript/wiki/No-New-Utility-Types"
41+
required: true
4342
- label: 'This feature would agree with the rest of our Design Goals: https://github.com/Microsoft/TypeScript/wiki/TypeScript-Design-Goals'
4443
required: true
4544
- type: textarea
@@ -54,8 +53,7 @@ body:
5453
attributes:
5554
label: '📃 Motivating Example'
5655
description: |
57-
If you were announcing this feature in a blog post, what's a short
58-
explanation that shows a developer why this feature improves the language?
56+
If you were announcing this feature in a blog post, what's a short explanation that shows a developer why this feature improves the language?
5957
validations:
6058
required: true
6159
- type: textarea

.github/ISSUE_TEMPLATE/lib_change.yml

+5-11
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: 'Library change'
2-
description: 'Fix or improve issues with built-in type definitions like `lib.dom.d.ts`, `lib.es6.d.ts`, etc.'
2+
description: 'Fix or improve issues with built-in type definitions like `lib.es6.d.ts`, etc.'
33
body:
44
- type: markdown
55
attributes:
@@ -12,18 +12,13 @@ body:
1212
* Array methods - see https://github.com/microsoft/TypeScript/issues/36554
1313
* `parseInt`, `parseFloat`, `isFinite`, `isNaN`, etc. - see https://github.com/microsoft/TypeScript/issues/4002
1414
15-
16-
The DOM lib is maintained elsewhere and you can skip a step by filing issues/PRs for the DOM at that repo.
17-
See https://github.com/microsoft/TypeScript-DOM-lib-generator
15+
The DOM lib is maintained elsewhere and you can skip a step by filing issues/PRs for the DOM at that repo. See https://github.com/microsoft/TypeScript-DOM-lib-generator
1816
- type: markdown
1917
attributes:
2018
value: |
21-
If you're missing common new methods like `Array.includes`, you may have a misconfigured project.
22-
Try setting `lib: "es2020"` and checking whether the type you want is present.
23-
You can diagnose further by running `tsc` with `--listFilesOnly` or `--showConfig`.
19+
If you're missing common new methods like `Array.includes`, you may have a misconfigured project. Try setting `lib: "es2020"` and checking whether the type you want is present. You can diagnose further by running `tsc` with `--listFilesOnly` or `--showConfig`.
2420
25-
Conversely, if you are seeing built-in methods you expect to *not* see, check your 'lib' setting or review your dependencies for lib/reference directives that might be polluting
26-
your global scope. This is common when using the 'node' type library. See https://github.com/microsoft/TypeScript/issues/40184
21+
Conversely, if you are seeing built-in methods you expect to *not* see, check your 'lib' setting or review your dependencies for lib/reference directives that might be polluting your global scope. This is common when using the 'node' type library. See https://github.com/microsoft/TypeScript/issues/40184
2722
- type: input
2823
id: compilation_target
2924
attributes:
@@ -58,5 +53,4 @@ body:
5853
attributes:
5954
label: 'Documentation Link'
6055
description: |
61-
Link to relevant documentation (e.g. MDN, W3C, ECMAScript Spec) to consult for this property.
62-
Note that lib.dom.d.ts intentionally does not include browser-specific extensions or early experimental features.
56+
Link to relevant documentation (e.g. MDN, W3C, ECMAScript Spec) to consult for this property. Note that lib.dom.d.ts intentionally does not include browser-specific extensions or early experimental features.

.github/ISSUE_TEMPLATE/module_resolution.yml

+1-2
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,7 @@ body:
2727
4. The configuration of the target module
2828
5. A difference in runtime behavior
2929
30-
You will also be required to post a cloneable repository.
31-
This repo must involve running `tsc`, not a third-party tool (e.g. vue-tsc, ngc, expo, ...)
30+
You will also be required to post a cloneable repository. This repo must involve running `tsc`, not a third-party tool (e.g. vue-tsc, ngc, expo, ...)
3231
3332
- type: input
3433
id: repo-url

.github/dependabot.yml

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# To get started with Dependabot version updates, you'll need to specify which
2+
# package ecosystems to update and where the package manifests are located.
3+
# Please see the documentation for all configuration options:
4+
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
5+
6+
version: 2
7+
updates:
8+
- package-ecosystem: 'github-actions'
9+
directory: '/'
10+
schedule:
11+
interval: 'weekly'
12+
groups:
13+
github-actions:
14+
patterns:
15+
- '*'

.github/pr_owners.txt

+1
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,4 @@ jakebailey
1313
DanielRosenwasser
1414
navya9singh
1515
iisaduan
16+
dependabot
+5-5
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
2-
"project": "../../src/tsconfig.json",
3-
"source": "../../package.json",
4-
"package": "../../package.json",
5-
"out": "../../typescript.lsif"
6-
}
2+
"project": "../../src/tsconfig.json",
3+
"source": "../../package.json",
4+
"package": "../../package.json",
5+
"out": "../../typescript.lsif"
6+
}

.github/workflows/accept-baselines-fix-lints.yaml

+4-5
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,11 @@ jobs:
1616
build:
1717
runs-on: ubuntu-latest
1818

19-
permissions:
20-
contents: write
21-
2219
steps:
23-
- uses: actions/checkout@v3
24-
- uses: actions/setup-node@v3
20+
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
21+
with:
22+
token: ${{ secrets.TS_BOT_GITHUB_TOKEN }}
23+
- uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1
2524

2625
- name: Configure Git, Run Tests, Update Baselines, Apply Fixes
2726
run: |

0 commit comments

Comments
 (0)