fw-03 step 03 — Scheduling, then rebuild it as signals
Goal
Batch the effects, then discover how much of your Vue implementation was essential versus Vue-specific.
Tasks
- Scheduler. A deduplicated queue flushed on a microtask. Reproduce the un-batched case first: 1,000 writes in a loop, measured.
- Explain why a microtask is the right boundary, referencing
bi-11. - Now build
signals.jsfrom scratch —signal,computed,effect,batch. Do not refactor the Vue code into it. Copy the spec, adapt the API surface, and get it green. - Compare the two implementations. What was essential? What was Vue-specific? The answer is the finding.
- Fill your version of the four-model comparison table (React / Vue / signals / Redux) across: how it knows what changed, unit of update, what cost scales with, whether "state at time T" exists, and what tooling each demands.
Done when
- Batching measured before and after
-
signals.jswritten independently and passing an adapted spec - Comparison table filled in your own words
- Notebook entry: the Vue scheduler