Show HN: ArkType 3.0 – Set-theoretic precompiled TS validator

ssalbdivad 38 points 11 comments December 03, 2026
arktype.io · View on Hacker News

ibrary author here! since our last major release, agentic dev has drastically shifted the trade offs between a purely dynamic library import and an extra build step that can optimize bundle size and startup time. arktype 3.0's headline feature is `@ark/aot`, which allows users to opt into a precompilation process that fully leverages the capabilities of our set-theoretic type system to output JS that is 15x faster to validate, 21x smaller and 63x quicker to start than Zod 4. in our internal tests, agents have generally been successful in one shotting a migration, so testing it out on a branch is cheap! would love to hear your thoughts and answer any questions. thanks, David

Discussion Highlights (6 comments)

question9876

Is this related to ArkTS in any way?

jadbox

ArkType is one of my favorite things in Typescript. It's elegent, reasonably terse, and fully utilizes the capabilities of Typescript to do things that is nearly impossible in other languages to do safely.

Cu3PO42

I'm particular excited for how well this plays with Bun's new AOT. One of the biggest hurdles for me where runtime codegen for type validation.

0x696C6961

I've mostly stayed away from ArkType because of the compile times. But I wonder if that still makes sense with the Go rewrite.

Benjamin_Dobell

I tried ArkType a couple of years ago and really like the idea but ran into limitations pretty fast compared to the TypeScript compiler. Specifically, I make extensive use of mapped types to enforce through-out the codebase that introducing something new into the codebase immediately raises errors everywhere that new thing needs to be plugged in. Was already powerful for humans, but is even more so with LLMs. Has there been any movement on mapped types?

faangguyindia

LLMs tend to be comparatively worse at TypeScript, JavaScript, and Python compared to Rust, which has far less code in the training corpus. In our test we found rust > java/c# > php > python > go > javascript

Semantic search powered by Rivestack pgvector
4,908 stories · 45,036 chunks indexed