@comment-labs/tsconfig
v1.0.0-beta.6
Published
Base tsconfig for comment-labs packages
Readme
@comment-labs/tsconfig
Shared TypeScript configuration presets for comment-labs projects.
Installation
pnpm add -D @comment-labs/tsconfig typescriptTypeScript ^5.9.2 || ^6.x is required.
Usage
Create a tsconfig.json in your project and extend the preset that matches your target runtime:
{
"extends": "@comment-labs/tsconfig/node",
"compilerOptions": {
"paths": {
"#/*": ["./src/*"]
}
},
"include": ["src/**/*", "*.ts"]
}Then type-check with:
pnpm tsc --noEmitPicking a preset
| Project type | Extend path |
|---|---|
| Node.js | @comment-labs/tsconfig/node |
| Cloudflare Workers | @comment-labs/tsconfig/workers |
| Workers with React | @comment-labs/tsconfig/react-workers |
| Astro | @comment-labs/tsconfig/astro-workers |
| Astro with React | @comment-labs/tsconfig/react-astro |
| Astro with React on Workers | @comment-labs/tsconfig/react-astro-workers |
| React web | @comment-labs/tsconfig/react |
| React Native / Expo | @comment-labs/tsconfig/react-native |
If none of these fit, fall back to @comment-labs/tsconfig/base.
All presets enable strict type checking, bundler module resolution, isolated modules and target ES2023.
