From 0a4a205fbe847f3c6d7608ef61d79a47f294b2c9 Mon Sep 17 00:00:00 2001 From: Michael Telatynski <7t3chguy@gmail.com> Date: Fri, 7 Jul 2023 14:46:14 +0100 Subject: [PATCH] Enable strictPropertyInitialization (#25735) --- .github/workflows/static_analysis.yaml | 38 -------------------------- tsconfig.json | 3 +- 2 files changed, 1 insertion(+), 40 deletions(-) diff --git a/.github/workflows/static_analysis.yaml b/.github/workflows/static_analysis.yaml index 61f5c20408..0384758a6b 100644 --- a/.github/workflows/static_analysis.yaml +++ b/.github/workflows/static_analysis.yaml @@ -26,44 +26,6 @@ jobs: - name: Typecheck run: "yarn run lint:types" - tsc-strict: - name: Typescript Strict Error Checker - if: github.event_name == 'pull_request' - runs-on: ubuntu-latest - permissions: - pull-requests: read - checks: write - steps: - - uses: actions/checkout@v3 - - - name: Install Deps - run: "scripts/layered.sh" - - - name: Get diff lines - id: diff - uses: Equip-Collaboration/diff-line-numbers@e752977e2cb4207d671bb9e4dad18c07c1b73d52 # v1.1.0 - with: - include: '["\\.tsx?$"]' - - - name: Detecting files changed - id: files - uses: futuratrepadeira/changed-files@0239328a3a6268aad16af7c3e4efc78e32d6c0f0 # v4.0.1 - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} - pattern: '^.*\.tsx?$' - - - uses: t3chguy/typescript-check-action@main - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} - use-check: false - check-fail-mode: added - output-behaviour: annotate - ts-extra-args: "--strict --noImplicitAny" - files-changed: ${{ steps.files.outputs.files_updated }} - files-added: ${{ steps.files.outputs.files_created }} - files-deleted: ${{ steps.files.outputs.files_deleted }} - line-numbers: ${{ steps.diff.outputs.lineNumbers }} - i18n_lint: name: "i18n Check" uses: matrix-org/matrix-react-sdk/.github/workflows/i18n_check.yml@develop diff --git a/tsconfig.json b/tsconfig.json index 3c0a77e8b0..ac8ea2d73f 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -13,8 +13,7 @@ "declaration": true, "jsx": "react", "lib": ["es2020", "dom", "dom.iterable"], - "strict": true, - "useUnknownInCatchVariables": false + "strict": true }, "include": [ "./node_modules/matrix-js-sdk/src/@types/*.d.ts",