Get the latest tech news

A lightweight TypeScript library for assertion-based runtime data validation


A lightweight TypeScript library for assertion-based runtime data validation. - nimeshnayaju/decode-kit

decode-kit provides assertion-based validation that refines your types in-place — no cloning, no transformations, and minimal runtime overhead. decode-kit instead asserts types directly - this provides several performance benefits as no time is spent copying arrays, strings or nested objects. This error object includes the path to the exact location of the validation failure (e.g., nested objects/arrays), the expected schema and ruleset that the value failed to match.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of TypeScript

TypeScript

Photo of assertion

assertion

Related news:

News photo

Node.js is able to execute TypeScript files without additional configuration

News photo

Comptime.ts: compile-time expressions for TypeScript

News photo

Rust, Python, and TypeScript: the new trifecta