Packages

ata-validator

1.61.3 · 29 Oct 2026MIT21.8k / weekRepositoryHomepagenpmAtom feed

Your version

1.56.0

18 Oct 2026Where it was published

1.61.3 is the newest release of 1.x.

In short

6 changed

Release note

Changed

  • The browser build (the browser export condition, which Vite, webpack, Rollup and esbuild use for a page) no longer puts the code generator in the page. Every schema starts on the interpreted engine, and a validator called a thousand times within a second loads the generator through a dynamic import, which bundlers split into a chunk of its own, and is rebuilt on generated code in place, one validator per idle task, so that several turning hot together do not hold the main thread (lib/tiering.js). Calls spread out further, a form checked as the user types, never load it: there generated code would save tens of nanoseconds a check against about 6 ms to load the generator and compile. Once rebuilt, a validator is as fast as one compiled from the start (16 ns a check on a form schema, both ways). The answers are the same on both engines, valid and errors alike. On a react-jsonschema-form page the validator's share of the first load goes from 134.7 KB to 57.5 KB gzipped with esbuild's splitting (205.9 KB for the whole page with Vite, 280.2 before); the generator chunk is 77 to 80 KB when it loads. A bundler that does not split chunks puts it back in the page, as before. Where code generation is blocked the chunk is never fetched.

  • ata-validator/codegen registers the generator at once, for a page that wants generated code from the first call.

  • The docs no longer point pages under a strict Content-Security-Policy or Manifest V3 extensions to ata-validator/lite: the browser build checks whether generated code can run before it fetches the generator, so ata-validator covers them. ata-validator/lite stays and works as before for code that imports it.

  • In the browser build, parse() waits for the generator: before it has loaded, it throws a TypeError that names ata-validator/codegen, and once it has, it works. The ahead-of-time bundle methods were already left out of the browser build and still point to ata-validator/aot. tests/test_browser_tiering.js covers the switch, a cold validator, blocked code generation and the eager import.

Size

  • ata-validator/lite is 55.7 KB gzipped, up 0.2 KB for the core's hooks for the on-demand generator, which lite does not carry.

Not changed

  • Node, the edge entry (workerd, edge-light) and ata build modules work as in 1.55.0. On Node the regression gate shows no group outside noise, and SchemaStore gives the same verdicts on 31,822 documents.