docs: add baseUrl to example tsconfig (#7884)

tsconfig requires compiler options with base url 

Without base url, TS errors appear such as `Cannot find module '@site/src/components/...`
This commit is contained in:
Charles Killer 2022-08-03 11:25:53 +01:00 committed by GitHub
parent 7ab2bd3234
commit 01ac2e0fca
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -28,7 +28,10 @@ Then add `tsconfig.json` to your project root with the following content:
```json title="tsconfig.json"
{
"extends": "@tsconfig/docusaurus/tsconfig.json"
"extends": "@tsconfig/docusaurus/tsconfig.json",
"compilerOptions": {
"baseUrl": "."
}
}
```