Type-Safe
Built with TypeScript from the ground up, providing excellent type inference and compile-time safety
Data structures, utilities, primitives, and domains with consistent APIs and strong type safety
npm install @wollybeard/kit
import { Arr, Num, Obj, Str } from '@wollybeard/kit'
// Array utilities
const doubled = Arr.map([1, 2, 3], x => x * 2)
// [2, 4, 6]
// Object utilities
const picked = Obj.pick({ a: 1, b: 2, c: 3 }, ['a', 'c'])
// { a: 1, c: 3 }
// String utilities
const slug = Str.Case.kebab('Hello World')
// 'hello-world'
// Number utilities
const clamped = Num.clamp(150, 0, 100)
// 100
Kit provides a comprehensive set of utilities that work together seamlessly:
*With
and *On
variantsKit follows these core principles: