fix(create-docusaurus): Fix TS issues on newly initialized sites (#10694)

This commit is contained in:
Sébastien Lorber 2024-11-19 12:08:35 +01:00 committed by GitHub
parent be7bace8bd
commit 5344bc105e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 9 additions and 9 deletions

View file

@ -160,12 +160,15 @@ jobs:
- name: Installation - name: Installation
run: yarn || yarn || yarn run: yarn || yarn || yarn
- name: Generate test-website project against main branch - 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 - name: Install test-website project with npm
run: npm install run: npm install
working-directory: ../test-website working-directory: ../test-website
env: env:
npm_config_registry: http://localhost:4873 npm_config_registry: http://localhost:4873
- name: TypeCheck website
working-directory: ../test-website
run: yarn typecheck
- name: Start test-website project - name: Start test-website project
run: npm run start -- --no-open run: npm run start -- --no-open
working-directory: ../test-website working-directory: ../test-website
@ -197,15 +200,17 @@ jobs:
- name: Installation - name: Installation
run: yarn || yarn || yarn run: yarn || yarn || yarn
- name: Generate test-website project against main branch - 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 - name: Install test-website project with pnpm
run: | run: |
npm install -g pnpm npm install -g pnpm
# Fix some peer dependencies errors pnpm install
pnpm add @algolia/client-search @types/react@17 typescript
working-directory: ../test-website working-directory: ../test-website
env: env:
npm_config_registry: http://localhost:4873 npm_config_registry: http://localhost:4873
- name: TypeCheck website
working-directory: ../test-website
run: yarn typecheck
- name: Start test-website project - name: Start test-website project
run: pnpm start --no-open run: pnpm start --no-open
working-directory: ../test-website working-directory: ../test-website

View file

@ -11,11 +11,6 @@
"moduleResolution": "bundler", "moduleResolution": "bundler",
"module": "esnext", "module": "esnext",
"noEmit": true, "noEmit": true,
"types": [
"node",
"@docusaurus/module-type-aliases",
"@docusaurus/theme-classic"
],
"baseUrl": ".", "baseUrl": ".",
"paths": { "paths": {
"@site/*": ["./*"] "@site/*": ["./*"]