From 5344bc105e720ff6d2b588bcd1568eb71e957148 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Lorber?= Date: Tue, 19 Nov 2024 12:08:35 +0100 Subject: [PATCH] fix(create-docusaurus): Fix TS issues on newly initialized sites (#10694) --- .github/workflows/tests-e2e.yml | 13 +++++++++---- packages/docusaurus-tsconfig/tsconfig.json | 5 ----- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/tests-e2e.yml b/.github/workflows/tests-e2e.yml index 632ec27d91..16d3e5b4d5 100644 --- a/.github/workflows/tests-e2e.yml +++ b/.github/workflows/tests-e2e.yml @@ -160,12 +160,15 @@ jobs: - name: Installation run: yarn || yarn || yarn - name: Generate test-website project against main branch - run: yarn test:build:website -s + run: yarn test:build:website -st - name: Install test-website project with npm run: npm install working-directory: ../test-website env: npm_config_registry: http://localhost:4873 + - name: TypeCheck website + working-directory: ../test-website + run: yarn typecheck - name: Start test-website project run: npm run start -- --no-open working-directory: ../test-website @@ -197,15 +200,17 @@ jobs: - name: Installation run: yarn || yarn || yarn - name: Generate test-website project against main branch - run: yarn test:build:website -s + run: yarn test:build:website -st - name: Install test-website project with pnpm run: | npm install -g pnpm - # Fix some peer dependencies errors - pnpm add @algolia/client-search @types/react@17 typescript + pnpm install working-directory: ../test-website env: npm_config_registry: http://localhost:4873 + - name: TypeCheck website + working-directory: ../test-website + run: yarn typecheck - name: Start test-website project run: pnpm start --no-open working-directory: ../test-website diff --git a/packages/docusaurus-tsconfig/tsconfig.json b/packages/docusaurus-tsconfig/tsconfig.json index d7dca8ef2a..b89e41d756 100644 --- a/packages/docusaurus-tsconfig/tsconfig.json +++ b/packages/docusaurus-tsconfig/tsconfig.json @@ -11,11 +11,6 @@ "moduleResolution": "bundler", "module": "esnext", "noEmit": true, - "types": [ - "node", - "@docusaurus/module-type-aliases", - "@docusaurus/theme-classic" - ], "baseUrl": ".", "paths": { "@site/*": ["./*"]