Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into dont-widen-computed-p…
Browse files Browse the repository at this point in the history
…rop-wiht-patterns

# Conflicts:
#	tests/baselines/reference/indexSignatures1.types
  • Loading branch information
Andarist committed May 3, 2024
2 parents 47cb307 + 3a74ec4 commit e0df494
Show file tree
Hide file tree
Showing 20,450 changed files with 1,355,834 additions and 441,737 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
22 changes: 12 additions & 10 deletions .dprint.jsonc
Original file line number Diff line number Diff line change
Expand Up @@ -19,17 +19,17 @@
"arrowFunction.useParentheses": "preferNone",
"conditionalExpression.linePerExpression": false, // Keep our "match/case"-ish conditionals.
"functionExpression.spaceAfterFunctionKeyword": true,
"importDeclaration.forceMultiLine": true,
"importDeclaration.forceMultiLine": "whenMultiple",
"constructorType.spaceAfterNewKeyword": true,
"constructSignature.spaceAfterNewKeyword": true,

// Let eslint-plugin-simple-import-sort handle this.
"module.sortImportDeclarations": "maintain",
"module.sortExportDeclarations": "maintain",
"exportDeclaration.sortNamedExports": "maintain",
"importDeclaration.sortNamedImports": "maintain"
"module.sortImportDeclarations": "caseInsensitive",
"module.sortExportDeclarations": "caseInsensitive",
"exportDeclaration.sortNamedExports": "caseInsensitive",
"importDeclaration.sortNamedImports": "caseInsensitive"
},
"prettier": {
"newLineKind": "lf",
"associations": [
"**/*.{yaml,yml}"
],
Expand All @@ -43,6 +43,7 @@
"trailingCommas": "never"
},
"excludes": [
"**/.git",
"**/node_modules",
"**/*-lock.json",
"coverage/**",
Expand All @@ -51,12 +52,13 @@
"tests/**",
"internal/**",
"**/*.generated.*",
"scripts/*.d.*"
"scripts/*.d.*",
"**/_namespaces/**"
],
// Note: if adding new languages, make sure settings.template.json is updated too.
"plugins": [
"https://plugins.dprint.dev/typescript-0.88.3.wasm",
"https://plugins.dprint.dev/json-0.19.0.wasm",
"https://plugins.dprint.dev/prettier-0.27.0.json@3557a62b4507c55a47d8cde0683195b14d13c41dda66d0f0b0e111aed107e2fe"
"https://plugins.dprint.dev/typescript-0.90.0.wasm",
"https://plugins.dprint.dev/json-0.19.2.wasm",
"https://plugins.dprint.dev/prettier-0.39.0.json@896b70f29ef8213c1b0ba81a93cee9c2d4f39ac2194040313cd433906db7bc7c"
]
}
File renamed without changes.
49 changes: 27 additions & 22 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,7 @@
],
"plugins": [
"@typescript-eslint",
"no-null",
"eslint-plugin-local",
"simple-import-sort"
"eslint-plugin-local"
],
"ignorePatterns": [
"**/node_modules/**",
Expand Down Expand Up @@ -61,6 +59,18 @@
"prefer-object-spread": "error",
"unicode-bom": ["error", "never"],

"no-restricted-syntax": [
"error",
{
"selector": "Literal[raw=null]",
"message": "Avoid using null; use undefined instead."
},
{
"selector": "TSNullKeyword",
"message": "Avoid using null; use undefined instead."
}
],

// Enabled in eslint:recommended, but not applicable here
"no-extra-boolean-cast": "off",
"no-case-declarations": "off",
Expand All @@ -82,6 +92,10 @@
{ "selector": "property", "format": null }
],

"@typescript-eslint/unified-signatures": "error",
"no-unused-expressions": "off",
"@typescript-eslint/no-unused-expressions": ["error", { "allowTernary": true }],

// Rules enabled in typescript-eslint configs that are not applicable here
"@typescript-eslint/ban-ts-comment": "off",
"@typescript-eslint/class-literal-property-style": "off",
Expand All @@ -105,9 +119,15 @@
}
}
],

// Todo: For each of these, investigate whether we want to enable them ✨
"@typescript-eslint/no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": [
"warn",
{
// Ignore: (solely underscores | starting with exactly one underscore)
"argsIgnorePattern": "^(_+$|_[^_])",
"varsIgnorePattern": "^(_+$|_[^_])"
}
],
"@typescript-eslint/no-inferrable-types": "off",

// Pending https://github.com/typescript-eslint/typescript-eslint/issues/4820
"@typescript-eslint/prefer-optional-chain": "off",
Expand All @@ -124,14 +144,7 @@
"local/no-in-operator": "error",
"local/debug-assert": "error",
"local/no-keywords": "error",
"local/jsdoc-format": "error",

// eslint-plugin-no-null
"no-null/no-null": "error",

// eslint-plugin-simple-import-sort
"simple-import-sort/imports": "error",
"simple-import-sort/exports": "error"
"local/jsdoc-format": "error"
},
"overrides": [
// By default, the ESLint CLI only looks at .js files. But, it will also look at
Expand All @@ -158,14 +171,6 @@
{ "name": "exports" }
]
}
},
{
// These files contain imports in a specific order that are generally unsafe to modify.
"files": ["**/_namespaces/**"],
"rules": {
"simple-import-sort/imports": "off",
"simple-import-sort/exports": "off"
}
}
]
}
5 changes: 4 additions & 1 deletion .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@ description: 'Create a report to help us improve TypeScript'
body:
- type: markdown
attributes:
value: Please fill in each section completely. Thank you!
value: |
🔍 Please [search thoroughly in GitHub](https://github.com/Microsoft/TypeScript/search?type=Issues) or by the query `site:github.com/microsoft/TypeScript <your keywords>` in your favorite search engine before reporting a new bug as most bugs are very likely to find precedents.
Please fill in each section completely. Thank you!
- type: textarea
id: search_terms
attributes:
Expand Down
30 changes: 15 additions & 15 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
---
blank_issues_enabled: false
contact_links:
- about: 'Please ask and answer usage questions on Stack Overflow.'
name: Question
url: 'https://stackoverflow.com/questions/tagged/typescript'
- about: 'Alternatively, you can use the TypeScript Community Discord.'
name: Chat
url: 'https://discord.gg/typescript'
- about: 'Please check the FAQ before filing new issues'
name: 'TypeScript FAQ'
url: 'https://github.com/microsoft/TypeScript/wiki/FAQ'
- about: 'Please raise issues about the site on its own repo.'
name: Website
url: 'https://github.com/microsoft/TypeScript-Website/issues/new'
---
blank_issues_enabled: false
contact_links:
- about: 'Please ask and answer usage questions on Stack Overflow.'
name: Question
url: 'https://stackoverflow.com/questions/tagged/typescript'
- about: 'Alternatively, you can use the TypeScript Community Discord.'
name: Chat
url: 'https://discord.gg/typescript'
- about: 'Please check the FAQ before filing new issues'
name: 'TypeScript FAQ'
url: 'https://github.com/microsoft/TypeScript/wiki/FAQ'
- about: 'Please raise issues about the site on its own repo.'
name: Website
url: 'https://github.com/microsoft/TypeScript-Website/issues/new'
15 changes: 10 additions & 5 deletions .github/ISSUE_TEMPLATE/feature_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,22 @@ description: 'Suggest an idea'
body:
- type: markdown
attributes:
value: 'Please fill in each section completely. Thank you!'
value: |
💡 Did you know? TypeScript has over 2,000 open suggestions!
🔎 Please [search thoroughly in GitHub](https://github.com/Microsoft/TypeScript/search?type=Issues) or by the query `site:github.com/microsoft/TypeScript <your keywords>` in your favorite search engine before logging new feature requests as most common ideas already have a proposal in progress.
The "Common Feature Requests" section of the FAQ lists many popular requests: https://github.com/Microsoft/TypeScript/wiki/FAQ#common-feature-requests
Please fill in each section completely. Thank you!
- type: textarea
id: search_terms
attributes:
label: '🔍 Search Terms'
description: |
💡 Did you know? TypeScript has over 2,000 open suggestions!
What search terms did you use when trying to find an existing suggestion?
🔎 Please search thoroughly before logging new feature requests as most common ideas already have a proposal in progress.
The "Common Feature Requests" section of the FAQ lists many popular requests: https://github.com/Microsoft/TypeScript/wiki/FAQ#common-feature-requests
List them here so people in the future can find this one more easily.
placeholder: |
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.
Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/lib_change.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: 'Library change'
description: 'Fix or improve issues with built-in type definitions like `lib.dom.d.ts`, `lib.es6.d.ts`, etc.'
description: 'Fix or improve issues with built-in type definitions like `lib.es6.d.ts`, etc.'
body:
- type: markdown
attributes:
Expand Down
6 changes: 0 additions & 6 deletions .github/workflow-resources/.lsifrc.json

This file was deleted.

6 changes: 4 additions & 2 deletions .github/workflows/accept-baselines-fix-lints.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,12 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
- uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4
with:
token: ${{ secrets.TS_BOT_GITHUB_TOKEN }}
- uses: actions/setup-node@8f152de45cc393bb48ce5d89d36b731f54556e65 # v4.0.0
- uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
with:
node-version: 'lts/*'

- name: Configure Git, Run Tests, Update Baselines, Apply Fixes
run: |
Expand Down
Loading

0 comments on commit e0df494

Please sign in to comment.