Skip to content

Commit 0265829

Browse files
committed
Merge branch 'master' into delete-legacy-empty-obj-type-param-rule
2 parents 248cbba + 67930fc commit 0265829

File tree

6,230 files changed

+543130
-240887
lines changed

Some content is hidden

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

6,230 files changed

+543130
-240887
lines changed

.dockerignore

+2-1
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ scripts/processDiagnosticMessages.js
2929
scripts/produceLKG.js
3030
scripts/importDefinitelyTypedTests/importDefinitelyTypedTests.js
3131
scripts/generateLocalizedDiagnosticMessages.js
32+
scripts/configureLanguageServiceBuild.js
3233
scripts/*.js.map
3334
scripts/typings/
3435
coverage/
@@ -45,4 +46,4 @@ TEST-results.xml
4546
package-lock.json
4647
tests
4748
.vscode
48-
.git
49+
.git

.eslintrc.json

+12-1
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@
2626
"@typescript-eslint/no-inferrable-types": "error",
2727
"@typescript-eslint/no-misused-new": "error",
2828
"@typescript-eslint/no-this-alias": "error",
29+
30+
"no-unused-expressions": "off",
31+
"@typescript-eslint/no-unused-expressions": ["error", { "allowTernary": true }],
32+
2933
"@typescript-eslint/prefer-for-of": "error",
3034
"@typescript-eslint/prefer-function-type": "error",
3135
"@typescript-eslint/prefer-namespace-keyword": "error",
@@ -36,6 +40,13 @@
3640
"semi": "off",
3741
"@typescript-eslint/semi": "error",
3842

43+
"space-before-function-paren": "off",
44+
"@typescript-eslint/space-before-function-paren": ["error", {
45+
"asyncArrow": "always",
46+
"anonymous": "always",
47+
"named": "never"
48+
}],
49+
3950
"@typescript-eslint/triple-slash-reference": "error",
4051
"@typescript-eslint/type-annotation-spacing": "error",
4152
"@typescript-eslint/unified-signatures": "error",
@@ -54,6 +65,7 @@
5465
"simple-indent": "error",
5566
"debug-assert": "error",
5667
"no-keywords": "error",
68+
"one-namespace-per-file": "error",
5769

5870
// eslint-plugin-import
5971
"import/no-extraneous-dependencies": ["error", { "optionalDependencies": false }],
@@ -96,7 +108,6 @@
96108
"no-trailing-spaces": "error",
97109
"no-undef-init": "error",
98110
"no-unsafe-finally": "error",
99-
"no-unused-expressions": ["error", { "allowTernary": true }],
100111
"no-unused-labels": "error",
101112
"no-var": "error",
102113
"object-shorthand": "error",

.github/ISSUE_TEMPLATE/Bug_report.md

+44-37
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,44 @@
1-
---
2-
name: Bug report
3-
about: Create a report to help us improve
4-
5-
---
6-
7-
<!-- 🚨 STOP 🚨 𝗦𝗧𝗢𝗣 🚨 𝑺𝑻𝑶𝑷 🚨
8-
9-
Half of all issues filed here are duplicates, answered in the FAQ, or not appropriate for the bug tracker. Even if you think you've found a *bug*, please read the FAQ first, especially the Common "Bugs" That Aren't Bugs section!
10-
11-
Please help us by doing the following steps before logging an issue:
12-
* Search: https://github.com/Microsoft/TypeScript/search?type=Issues
13-
* Read the FAQ: https://github.com/Microsoft/TypeScript/wiki/FAQ
14-
15-
Please fill in the *entire* template below.
16-
-->
17-
18-
<!-- Please try to reproduce the issue with `typescript@next`. It may have already been fixed. -->
19-
**TypeScript Version:** 3.4.0-dev.201xxxxx
20-
21-
<!-- Search terms you tried before logging this (so others can find this issue more easily) -->
22-
**Search Terms:**
23-
24-
**Code**
25-
26-
```ts
27-
// A *self-contained* demonstration of the problem follows...
28-
// Test this by running `tsc` on the command-line, rather than through another build tool such as Gulp, Webpack, etc.
29-
```
30-
31-
**Expected behavior:**
32-
33-
**Actual behavior:**
34-
35-
**Playground Link:** <!-- A link to a TypeScript Playground "Share" link which demonstrates this behavior -->
36-
37-
**Related Issues:** <!-- Did you find other bugs that looked similar? -->
1+
---
2+
name: Bug
3+
about: Create a report to help us improve TypeScript
4+
title: ''
5+
labels: ''
6+
assignees: ''
7+
8+
---
9+
10+
<!-- 🚨 STOP 🚨 𝗦𝗧𝗢𝗣 🚨 𝑺𝑻𝑶𝑷 🚨
11+
12+
Half of all issues filed here are duplicates, answered in the FAQ, or not appropriate for the bug tracker. Even if you think you've found a *bug*, please read the FAQ first, especially the Common "Bugs" That Aren't Bugs section!
13+
14+
Please help us by doing the following steps before logging an issue:
15+
* Search: https://github.com/Microsoft/TypeScript/search?type=Issues
16+
* Read the FAQ: https://github.com/Microsoft/TypeScript/wiki/FAQ
17+
18+
Please fill in the *entire* template below.
19+
-->
20+
21+
<!--
22+
Please try to reproduce the issue with the latest published version. It may have already been fixed.
23+
For npm: `typescript@next`
24+
This is also the 'Nightly' version in the playground: http://www.typescriptlang.org/play/?ts=Nightly
25+
-->
26+
**TypeScript Version:** 3.7.x-dev.201xxxxx
27+
28+
<!-- Search terms you tried before logging this (so others can find this issue more easily) -->
29+
**Search Terms:**
30+
31+
**Code**
32+
33+
```ts
34+
// A *self-contained* demonstration of the problem follows...
35+
// Test this by running `tsc` on the command-line, rather than through another build tool such as Gulp, Webpack, etc.
36+
```
37+
38+
**Expected behavior:**
39+
40+
**Actual behavior:**
41+
42+
**Playground Link:** <!-- A link to a TypeScript Playground "Share" link which demonstrates this behavior -->
43+
44+
**Related Issues:** <!-- Did you find other bugs that looked similar? -->
+47-45
Original file line numberDiff line numberDiff line change
@@ -1,45 +1,47 @@
1-
---
2-
name: Feature request
3-
about: Suggest an idea for this project
4-
5-
---
6-
7-
<!-- 🚨 STOP 🚨 𝗦𝗧𝗢𝗣 🚨 𝑺𝑻𝑶𝑷 🚨
8-
9-
Half of all issues filed here are duplicates, answered in the FAQ, or not appropriate for the bug tracker.
10-
11-
Please help us by doing the following steps before logging an issue:
12-
* Search: https://github.com/Microsoft/TypeScript/search?type=Issues
13-
* Read the FAQ, especially the "Common Feature Requests" section: https://github.com/Microsoft/TypeScript/wiki/FAQ
14-
15-
-->
16-
17-
## Search Terms
18-
19-
<!-- List of keywords you searched for before creating this issue. Write them down here so that others can find this suggestion more easily -->
20-
21-
## Suggestion
22-
23-
<!-- A summary of what you'd like to see added or changed -->
24-
25-
## Use Cases
26-
27-
<!--
28-
What do you want to use this for?
29-
What shortcomings exist with current approaches?
30-
-->
31-
32-
## Examples
33-
34-
<!-- Show how this would be used and what the behavior would be -->
35-
36-
## Checklist
37-
38-
My suggestion meets these guidelines:
39-
40-
* [ ] This wouldn't be a breaking change in existing TypeScript/JavaScript code
41-
* [ ] This wouldn't change the runtime behavior of existing JavaScript code
42-
* [ ] This could be implemented without emitting different JS based on the types of the expressions
43-
* [ ] This isn't a runtime feature (e.g. library functionality, non-ECMAScript syntax with JavaScript output, etc.)
44-
* [ ] This feature would agree with the rest of [TypeScript's Design Goals](https://github.com/Microsoft/TypeScript/wiki/TypeScript-Design-Goals).
45-
1+
---
2+
name: Feature Request
3+
about: Suggest an idea
4+
title: ''
5+
labels: ''
6+
assignees: ''
7+
8+
---
9+
10+
<!-- 🚨 STOP 🚨 𝗦𝗧𝗢𝗣 🚨 𝑺𝑻𝑶𝑷 🚨
11+
12+
Half of all issues filed here are duplicates, answered in the FAQ, or not appropriate for the bug tracker.
13+
14+
Please help us by doing the following steps before logging an issue:
15+
* Search: https://github.com/Microsoft/TypeScript/search?type=Issues
16+
* Read the FAQ, especially the "Common Feature Requests" section: https://github.com/Microsoft/TypeScript/wiki/FAQ
17+
18+
-->
19+
20+
## Search Terms
21+
22+
<!-- List of keywords you searched for before creating this issue. Write them down here so that others can find this suggestion more easily -->
23+
24+
## Suggestion
25+
26+
<!-- A summary of what you'd like to see added or changed -->
27+
28+
## Use Cases
29+
30+
<!--
31+
What do you want to use this for?
32+
What shortcomings exist with current approaches?
33+
-->
34+
35+
## Examples
36+
37+
<!-- Show how this would be used and what the behavior would be -->
38+
39+
## Checklist
40+
41+
My suggestion meets these guidelines:
42+
43+
* [ ] This wouldn't be a breaking change in existing TypeScript/JavaScript code
44+
* [ ] This wouldn't change the runtime behavior of existing JavaScript code
45+
* [ ] This could be implemented without emitting different JS based on the types of the expressions
46+
* [ ] This isn't a runtime feature (e.g. library functionality, non-ECMAScript syntax with JavaScript output, etc.)
47+
* [ ] This feature would agree with the rest of [TypeScript's Design Goals](https://github.com/Microsoft/TypeScript/wiki/TypeScript-Design-Goals).

.github/ISSUE_TEMPLATE/Question.md

-15
This file was deleted.

.github/ISSUE_TEMPLATE/config.yml

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

.github/pr_owners.txt

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
sandersn
2+
elibarzilay
3+
weswigham
4+
andrewbranch
5+
RyanCavanaugh
6+
sheetalkamat
7+
orta
8+
rbuckton

.github/workflows/ci.yml

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
- release-*
8+
pull_request:
9+
branches:
10+
- master
11+
- release-*
12+
13+
jobs:
14+
build:
15+
runs-on: ubuntu-latest
16+
17+
strategy:
18+
matrix:
19+
node-version: [8.x, 10.x, 12.x]
20+
21+
steps:
22+
- uses: actions/checkout@v1
23+
with:
24+
fetch-depth: 5
25+
- name: Use node version ${{ matrix.node-version }}
26+
uses: actions/setup-node@v1
27+
with:
28+
node-version: ${{ matrix.node-version }}
29+
- name: Remove existing TypeScript
30+
run: |
31+
npm uninstall typescript --no-save
32+
npm uninstall tslint --no-save
33+
- name: npm install and test
34+
run: |
35+
npm install
36+
npm update
37+
npm test
38+
- name: Validate the browser can import TypeScript
39+
run: gulp test-browser-integration
40+
+38
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: New Release Branch
2+
3+
on:
4+
repository_dispatch:
5+
types: new-release-branch
6+
7+
jobs:
8+
build:
9+
runs-on: ubuntu-latest
10+
11+
steps:
12+
- name: Use node version 12.x
13+
uses: actions/setup-node@v1
14+
with:
15+
node-version: 12.x
16+
- uses: actions/checkout@v2
17+
with:
18+
fetch-depth: 5
19+
- run: |
20+
git checkout -b ${{ github.event.client_payload.branch_name }}
21+
sed -i -e 's/"version": ".*"/"version": "${{ github.event.client_payload.package_version }}"/g' package.json
22+
sed -i -e 's/const versionMajorMinor = ".*"/const versionMajorMinor = "${{ github.event.client_payload.core_major_minor }}"/g' src/compiler/corePublic.ts
23+
sed -i -e 's/const versionMajorMinor = ".*"/const versionMajorMinor = "${{ github.event.client_payload.core_major_minor }}"/g' tests/baselines/reference/api/typescript.d.ts
24+
sed -i -e 's/const versionMajorMinor = ".*"/const versionMajorMinor = "${{ github.event.client_payload.core_major_minor }}"/g' tests/baselines/reference/api/tsserverlibrary.d.ts
25+
sed -i -e 's/const version = `${versionMajorMinor}.0-.*`/const version = `${versionMajorMinor}.0-${{ github.event.client_payload.core_tag || 'dev' }}`/g' src/compiler/corePublic.ts
26+
npm install
27+
gulp LKG
28+
npm test
29+
git diff
30+
git add package.json
31+
git add src/compiler/corePublic.ts
32+
git add tests/baselines/reference/api/typescript.d.ts
33+
git add tests/baselines/reference/api/tsserverlibrary.d.ts
34+
git add ./lib
35+
git config user.email "[email protected]"
36+
git config user.name "TypeScript Bot"
37+
git commit -m 'Bump version to ${{ github.event.client_payload.package_version }} and LKG'
38+
git push --set-upstream origin ${{ github.event.client_payload.branch_name }}

.github/workflows/nightly.yaml

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Publish Nightly
2+
3+
on:
4+
schedule:
5+
- cron: '0 7 * * *'
6+
repository_dispatch:
7+
types: publish-nightly
8+
9+
jobs:
10+
build:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- uses: actions/checkout@v2
15+
- name: Use node version 12
16+
uses: actions/setup-node@v1
17+
with:
18+
node-version: 12
19+
registry-url: https://registry.npmjs.org/
20+
- name: Setup and publish nightly
21+
run: |
22+
npm whoami
23+
npm i
24+
gulp configure-nightly
25+
gulp LKG
26+
gulp runtests-parallel
27+
gulp clean
28+
npm publish --tag next
29+
env:
30+
NODE_AUTH_TOKEN: ${{secrets.npm_token}}
31+
CI: true
32+

0 commit comments

Comments
 (0)