Skip to content

Commit

Permalink
Update tsconfig.json and docs
Browse files Browse the repository at this point in the history
  • Loading branch information
lachlancollins committed Dec 31, 2023
1 parent 013ac97 commit 6641c08
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion docs/build.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ The build config is quite opinionated, as it is designed to work with our intern
}
```

# ## vite.config.ts
## vite.config.ts

```ts
import { defineConfig, mergeConfig } from 'vite'
Expand All @@ -51,6 +51,10 @@ export default mergeConfig(
)
```

## tsconfig.json

- Ensure your `"include"` field includes `"vite.config.ts"`.

# Caveats

While this config _will_ work with most frameworks with a Vite adapter, it doesn't mean you _should_ use it for all frameworks. For instance, Svelte publishes [@sveltejs/package](https://www.npmjs.com/package/@sveltejs/package), and Angular publishes [ng-packagr](https://www.npmjs.com/package/ng-packagr). When a framework-specific build tool exists, this should be preferred.
2 changes: 1 addition & 1 deletion integrations/react/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,5 @@
"noUnusedParameters": true,
"noFallthroughCasesInSwitch": true
},
"include": ["src"]
"include": ["src", "vite.config.ts"]
}

0 comments on commit 6641c08

Please sign in to comment.