Skip to content
Eugene Lazutkin edited this page Aug 21, 2026 · 4 revisions

invariants-sidecar

Build status NPM version

invariants-sidecar turns library-declared invariants into verified data: a static-land dictionary completer (derive map, ap, … from a minimal base per the derivation lattice) with a law/consistency property-test generator targeting tape-six-fast-check's t.prop(), and a sidecar-artifact toolchain — discovery for an installed package, a strict frontmatter discriminator, a parser that yields inert data, an explicit check compiler, call-site guards via tape-six-invariant, and a verified: ci-gated apodictum oracle bridge. Zero runtime dependencies; claims are verified, never trusted.

import {complete, makeLawTests, makeConsistencyTests, runLaws} from 'invariants-sidecar';

const {module: M, derived, consistency} = complete(Maybe); // minimal base in, full module out

test('Maybe laws', async t => {
  await runLaws(t, makeLawTests(M, opts));
  await runLaws(t, makeConsistencyTests(Maybe, opts));
});

Search

🔍 Search this wiki — ranked, deep-linked search via wiki-search; install the bookmarklet to search in place. Fallback: GitHub wiki search.

Documentation

See the README for installation, usage, the sidecar format, and the API; llms.txt / llms-full.txt in the package carry the machine-readable reference.

Clone this wiki locally