is-kit 1.12.0 โ 1.12.1
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 +23 -2
- package/package.json +2 -1
package/README.md
CHANGED
|
@@ -23,6 +23,8 @@
|
|
|
23
23
|
</a>
|
|
24
24
|
</p>
|
|
25
25
|
|
|
26
|
+
<h2 align="center">Build small guards. Compose them.</h2>
|
|
27
|
+
|
|
26
28
|
`is-kit` is a lightweight, zero-dependency toolkit for building reusable TypeScript **type guards**.
|
|
27
29
|
|
|
28
30
|
It helps you write small `isFoo` functions, compose them into **richer runtime checks**, and keep **TypeScript narrowing** natural inside regular control flow.
|
|
@@ -34,7 +36,8 @@ It helps you write small `isFoo` functions, compose them into **richer runtime c
|
|
|
34
36
|
- **Validate object** shapes and collections
|
|
35
37
|
- **Parse or assert** `unknown` values without a large schema framework
|
|
36
38
|
|
|
37
|
-
[๐ Documentation Site](https://is-kit-docs.vercel.app/)
|
|
39
|
+
[๐ Documentation Site](https://is-kit-docs.vercel.app/) ยท
|
|
40
|
+
[๐งญ Practical Guides](https://is-kit-docs.vercel.app/guides)
|
|
38
41
|
|
|
39
42
|
> Best for **app-internal narrowing, filtering, and reusable guards**.
|
|
40
43
|
|
|
@@ -71,12 +74,25 @@ bun add is-kit
|
|
|
71
74
|
npm install is-kit
|
|
72
75
|
# or
|
|
73
76
|
yarn add is-kit
|
|
77
|
+
# or
|
|
78
|
+
vlt install is-kit
|
|
74
79
|
```
|
|
75
80
|
|
|
76
81
|
ESM and CJS builds are available for npm consumers, and bundled types are included.
|
|
77
82
|
|
|
83
|
+
vlt requires registry configuration before installing a package by name. Run
|
|
84
|
+
`vlt setup` once if a registry has not been configured yet.
|
|
85
|
+
|
|
78
86
|
### JSR
|
|
79
87
|
|
|
88
|
+
Install the JSR package with vlt:
|
|
89
|
+
|
|
90
|
+
```bash
|
|
91
|
+
vlt install jsr:@nyaomaru/is-kit
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
Or import it directly in runtimes that support `jsr:` specifiers:
|
|
95
|
+
|
|
80
96
|
```ts
|
|
81
97
|
import { and, define, or } from 'jsr:@nyaomaru/is-kit';
|
|
82
98
|
```
|
|
@@ -583,7 +599,12 @@ public root exports are planned for removal.
|
|
|
583
599
|
|
|
584
600
|
For detailed API pages and more examples, see:
|
|
585
601
|
|
|
586
|
-
https://is-kit-docs.vercel.app/
|
|
602
|
+
- [Practical guides](https://is-kit-docs.vercel.app/guides)
|
|
603
|
+
- [API reference](https://is-kit-docs.vercel.app/api-reference)
|
|
604
|
+
- [Documentation home](https://is-kit-docs.vercel.app/)
|
|
605
|
+
|
|
606
|
+
Start with [How to safely filter null and undefined from arrays in
|
|
607
|
+
TypeScript](https://is-kit-docs.vercel.app/guides/filter-null-and-undefined).
|
|
587
608
|
|
|
588
609
|
## ๐จโ๐ป Development
|
|
589
610
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "is-kit",
|
|
3
|
-
"version": "1.12.
|
|
3
|
+
"version": "1.12.1",
|
|
4
4
|
"description": "Zero-dependency TypeScript runtime validation toolkit for composable type guards and natural type narrowing.",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"module": "./dist/index.mjs",
|
|
@@ -69,6 +69,7 @@
|
|
|
69
69
|
"test": "jest",
|
|
70
70
|
"test:types": "tsd",
|
|
71
71
|
"test:package": "node tests/package-smoke.mjs",
|
|
72
|
+
"test:package:vlt": "node tests/vlt-package-smoke.mjs",
|
|
72
73
|
"lint": "oxlint .",
|
|
73
74
|
"format": "oxfmt .",
|
|
74
75
|
"format:check": "oxfmt --check .",
|