Reference
Component Model
Look up syntax, contracts, layouts, algorithms, and exact behavior.
A TSXLight component is a server-resident object that can render a JSX-like subtree, hold mutable state, expose lifecycle hooks, and register callbacks. The rendered client output is a projection of that object, not the owner of the object.
type Component = {
props: Record<string, unknown>;
state?: Record<string, unknown>;
render(): TsxNode;
saveState?(): unknown;
loadState?(state: unknown): void;
afterRender?(): void;
};The custom JSX factory creates plain element records rather than React elements. Intrinsic elements become tag records; component constructors become component records; children are stored explicitly so the server renderer can walk the whole tree.