@kyh/tsconfig 1.1.13 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +31 -0
- package/base.json +2 -2
- package/package.json +5 -5
- package/internal-package.json +0 -11
package/README.md
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# @kyh/tsconfig
|
|
2
|
+
|
|
3
|
+
Shared TypeScript configs.
|
|
4
|
+
|
|
5
|
+
## Install
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
pnpm add -D @kyh/tsconfig
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Usage
|
|
12
|
+
|
|
13
|
+
```jsonc
|
|
14
|
+
// tsconfig.json
|
|
15
|
+
{
|
|
16
|
+
"extends": "@kyh/tsconfig/base.json",
|
|
17
|
+
"include": ["src"]
|
|
18
|
+
}
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
Configs:
|
|
22
|
+
|
|
23
|
+
- `base.json` — strict, `noUncheckedIndexedAccess`, bundler resolution, `noEmit`
|
|
24
|
+
|
|
25
|
+
`base.json` is the only config, and it's for **workspace packages and apps**. Point their
|
|
26
|
+
`exports` straight at source (`"." : "./src/index.ts"`) and give them no build step: tsserver
|
|
27
|
+
and the bundler both follow `exports` and read the `.ts`, so emitting `.d.ts` for them produces
|
|
28
|
+
artifacts nothing resolves.
|
|
29
|
+
|
|
30
|
+
Packages **published to npm** should not extend this at all — they inline their own tsconfig so
|
|
31
|
+
they build without depending on a shared workspace config.
|
package/base.json
CHANGED
package/package.json
CHANGED
package/internal-package.json
DELETED