Primer
The Primer section is context, not API. It’s the “why” behind the choices Phaze makes — where the patterns came from, what each contributor along the way added or shed, and what’s still open.
If you came here to build something, Setup is faster. The Primer is for when you want to know why Phaze looks the way it does.
In this section
Section titled “In this section”- State in Phaze — Phaze’s one-primitive, two-scope state story.
signal()inside a component = local; the same call at module level = shared (replaces context, Redux, Zustand). Plus the signal-as-discriminated-union state machine — the idiomatic way to model component modes. - A brief history of Signals — where the signal pattern actually started (it wasn’t Angular), who built each piece, what didn’t survive, and where Phaze fits in the lineage.
- A brief history of Directives — directives are older than React. Where the pattern came from (AngularJS, Knockout, Vue, Svelte, Solid), what survived, and how Phaze’s
use:lands on the contract Svelte and Solid converged on. - The elephant in the room — is Phaze faster than a pure function? Honest architectural answer about React’s per-update tax, what signals actually solve, and where Phaze lands on the speed/maintainability curve.
- It’s all about speed — TODO
- Effects in Phaze — for React/Preact developers tired of
useEffect. Whateffect()actually is, why it doesn’t have the footguns you’ve been working around for years, and the naming legacy React inherited from reactive frameworks and used wrong. - On priority and scheduling — why Phaze’s default scheduler is a single microtask queue (no
withPriority, no priorities), what scheduling priorities actually do, when you’d actually need them, and what the native browser primitives give you for free.
More chapters coming as Phaze’s design rationale fills in — likely covering the truly-reactive vs re-rendering distinction in depth, the choice to delete <Show> / <Switch> / <Dynamic>, the no-context stance, and the compiler’s role.