sveltelean
Version v0.18.0

Key numbers

SubjectValueSource
Behavior JavaScript of a page with native primitives only (button, dialog, popover)0 Bnative-only fixture
Tabs behavior with the shared kernel, for any number of tab lists1839 B brotliBudgets
A thousand tabs roots: ready, first click68.6 ms, 1.9 msResults
Table, a thousand rows: mount, sort287.3 ms, 156.1 msResults
Modal dialog, library JavaScript: Svelte Lean, Bits UI0 B brotli, 12378 B brotliComparison

Production builds, Vite 7.3.6, Svelte 5.57.1; timings are medians in Chromium on AMD EPYC 9555P 64-Core Processor; the comparison excludes Svelte's own runtime on both sides (Bits UI 2.19.3).

What is measured

  • Bytes of every entry point (raw, gzip, brotli) against its budget.
  • What consumer applications ship, asserted module by module in production builds.
  • Listeners at one and a thousand roots, counted by the runtime and by an independent addEventListener wrapper.
  • Startup and interaction timings, each as its own entry, never one score.
  • Heap, DOM nodes and listeners after repeated mount and unmount.

What is not claimed

  • No comparison beyond the published one: the Bits UI cases in benchmarks/compare, with their source and versions.
  • No cross-browser numbers: Chromium only; Firefox and WebKit runs do not exist yet.
  • No promise from a timing: it describes the recorded environment.

Every public claim and its evidence: docs/proof/claims.md.

Shipping invariants

Release-blocking, from ADR 0005.

InvariantWhere it is testedStatus
A. Native-only pages ship no behavior runtimefixtures/native-only; packages/primitives/scripts/size.mjs (native-only build)passing
B. Unused behaviors are absent from production outputfixtures/tabs-only, tabs-and-menu, manual-registration, table-basicpassing
C. Instance count does not multiply shared listenersapps/playground/tests/primitives/listeners.spec.ts (1 versus 1000 roots); packages/primitives/tests/tabs.test.tsexact assertion in the browser suite
D. Tier 2 state is lazypackages/primitives/tests/autocomplete.test.ts and select.test.ts; apps/playground/tests/primitives/lazy.spec.ts (no controller until a root is used, released on close)exact assertion in the browser suite
E. Compatibility code is opt-inNo compatibility module exists yet; the first one comes with a fixture.not applicable yet

Fixture status from fixtures/results.json (yarn test:fixtures, Node v22.23.3).

Proof hierarchy

LevelWhat it provesWhere
Level 1 · ArchitectureEach contract declares tier, events and native base; tests assert the root entry registers nothing.packages/primitives/src/<name>/contract.md and contract.ts
Level 2 · BuildConsumer fixtures assert which modules ship; size scripts record every entry point.fixtures/results.json, packages/*/artifacts/size.json
Level 3 · RuntimeListener counts at one and a thousand roots, keyboard and focus, JavaScript disabled, timings.apps/playground/tests, and live on the proof page of this site
Level 4 · ApplicationThis site runs on the packages it documents; the Settings demo composes primitives and the table.apps/docs, /demos/settings
  • Methodology: how each number is produced and reproduced.
  • Budgets: the limit next to each measured size.
  • Results: every measurement with its environment.
  • Proof: the live runtime of this site.