@codecompose/typescript-config
Advanced tools
Comparing version 1.1.3 to 1.2.0
@@ -8,7 +8,7 @@ { | ||
"declaration": true, | ||
"declarationMap": true, | ||
/* AND if you're building for a library in a monorepo: */ | ||
"composite": true, | ||
"declarationMap": true | ||
"composite": true | ||
} | ||
} |
{ | ||
"name": "@codecompose/typescript-config", | ||
"description": "Opinionated reusable TypeScript configurations", | ||
"version": "1.1.3", | ||
"version": "1.2.0", | ||
"license": "MIT", | ||
@@ -6,0 +6,0 @@ "author": "Thijs Koerselman", |
@@ -6,3 +6,3 @@ { | ||
"compilerOptions": { | ||
"lib": ["dom", "dom.iterable", "es2023"], | ||
"lib": ["dom", "dom.iterable", "esnext"], | ||
"jsx": "react-jsx", | ||
@@ -9,0 +9,0 @@ |
@@ -6,3 +6,3 @@ # typescript-config | ||
- A monorepo setup (\*) | ||
- Transpile with a bundler | ||
- Transpile using a bundler | ||
- Strict rules | ||
@@ -14,13 +14,13 @@ - Use of `src` and `dist` directories | ||
All configurations have `incremental` set to `true`. For this reason I recommend | ||
adding the following script to your manifest based on `del-cli`: | ||
## Warning | ||
`"clean": "del dist tsconfig.tsbuildinfo"` | ||
At the time of writing, not all tooling correctly interprets the extended | ||
config. | ||
In my experience, it can happen that builds get stuck in limbo and you need to | ||
delete the `tsbuildinfo` file to get things going again. | ||
- Next.js will require you to explicitly defined "includes". Give it "src" and | ||
it will inject its types on startup. | ||
- TSUP will not understand the tsconfig if you ask it to generate type | ||
definitions. I use tsc to generate the types, as demonstrated in | ||
[mono-ts](https://github.com/0x80/mono-ts). | ||
Source maps are not enabled, because we assume that your bundler will handle | ||
that. | ||
## Install | ||
@@ -42,2 +42,3 @@ | ||
- base | ||
- library | ||
@@ -49,1 +50,16 @@ - react-library | ||
- single-react-library | ||
For something else, like a CLI or E2E app you can probably just use the | ||
`base.json` configuration. | ||
## Assumptions and Recommendations | ||
Source maps are not enabled, because we assume that your bundler will handle | ||
that. | ||
All configurations have `incremental` set to `true`. In my experience, it can | ||
happen that builds get stuck in limbo and you need to delete the `tsbuildinfo` | ||
file to get things going again. For this reason I recommend adding the following | ||
script to your manifest based on `del-cli`: | ||
`"clean": "del dist tsconfig.tsbuildinfo"` |
@@ -7,4 +7,5 @@ { | ||
/* AND if you're building for a library: */ | ||
"declaration": true | ||
"declaration": true, | ||
"declarationMap": true | ||
} | ||
} |
@@ -6,8 +6,9 @@ { | ||
"compilerOptions": { | ||
"lib": ["dom", "dom.iterable", "es2023"], | ||
"lib": ["dom", "dom.iterable", "esnext"], | ||
"jsx": "react-jsx", | ||
/* AND if you're building for a library: */ | ||
"declaration": true | ||
"declaration": true, | ||
"declarationMap": true | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
6367
109
62