Performance Benchmarks

Real measured performance data from the What Framework test suite. All benchmarks run on Node.js v22.23.3.

Last updated · v0.13.10 · linux

Signals

Operation Ops/Second Time per Op
Signal create 2.1M ops/sec 0.5µs
Signal read (100x per iteration) 3.9M ops/sec 0.3µs
Signal write (no subscribers) 769K ops/sec 0.0013ms
Signal write (1 subscriber) 327K ops/sec 0.0031ms
Signal write (10 subscribers) 154K ops/sec 0.0065ms
Signal peek (untracked read) 1.8M ops/sec 0.5µs

Subscriber overhead is expected — effects run on every write.

Computed Values

Operation Ops/Second Time per Op
Computed create + read 592K ops/sec 0.0017ms
Computed chain (depth 5) 135K ops/sec 0.0074ms
Computed diamond dependency 255K ops/sec 0.0039ms

Effects

Operation Ops/Second Time per Op
Effect create + dispose 1.9M ops/sec 0.5µs
Effect with 10 signal deps 455K ops/sec 0.0022ms

Batching

Operation Ops/Second Time per Op
Batch 100 writes, 1 effect 373K ops/sec 0.0027ms
Batch 10 signals, 10 writes each 232K ops/sec 0.0043ms

Batching prevents intermediate computations, making 100 writes nearly as fast as 1.

Rendering (h function)

Operation Ops/Second Time per Op
Single element creation 5.1M ops/sec 0.2µs
Nested (3 levels) 4.0M ops/sec 0.3µs
List of 100 items 32K ops/sec 0.0308ms
Component call 8.5M ops/sec 0.1µs

Server-Side Rendering

Operation Ops/Second Time per Op
SSR simple element 355K ops/sec 0.0028ms
SSR nested tree 245K ops/sec 0.0041ms
SSR list of 100 items 7K ops/sec 0.1498ms
SSR component tree (50 items) 22K ops/sec 0.0448ms

Bundle Size

Package Size (gzipped)
what-framework (core) ~6.44 KB

Measured using gzip -9 compression.

Methodology

All benchmarks run on Node.js v22.23.3 with the following approach:

• Warmup: 100–1000 iterations discarded before measurement

• Iterations: 500–10,000 per test (varies by operation cost)

• Timing: High-resolution performance.now()

• Calculation: Trimmed mean (discard top/bottom 10%)

• Environment: linux, Node.js v22.23.3

• Automated: Benchmarks regenerate every 3 days via CI

Source code available in /benchmark directory. Run with npm run bench.