Fundamentals
Core architecture and concepts for Katalyst
Overview
Katalyst is built around three simple ideas:
- Proxy-wrapped Instances — each
New(className)returns a proxy that forwards reads/writes to a realInstancewhile adding reactive wiring. - Reactive State — a tiny
Stateprimitive withget,set, andonChangethat batches updates. - Declarative children —
Childrenprops accept arrays, nested fragments, functions, or State-backed arrays; Katalyst diffs and attaches/detaches Instances.
Architecture overview
Newconstructs a realInstanceand returns a lightweight proxy with metamethods for property access, assignment, calling, and equality.- Property assignment accepts
Stateobjects and functions (computed props).Statesubscriptions update the underlying Instance when values change. Childrenare handled by a small internal function that keeps a weak-keyed cache of attached children per parent and removes children that are no longer used.
Why this design?
- Minimalism: single-file runtime and a tiny API make the framework easy to audit and embed.
- Interoperability: because Katalyst operates with real Instances, existing Roblox APIs (TweenService, etc.) continue to work seamlessly.
