@threadplane/renderInterfacev0.3.4

RenderViewEntry

A view registry entry. Bare Type form is the legacy shape; the object form lets consumers attach a per-component fallback that mounts while any state-bound prop on the element is still unresolved. The fallback is monotonic per element instance: once the real component mounts, subsequent re-renders never revert to fallback even if a prop later resolves to undefined.

import type { RenderViewEntry } from '@threadplane/render';

Declaration

export interface RenderViewEntry  {
  component: Type<unknown>;
  description?: string;
  fallback?: Type<unknown>;
  schema?: StandardSchemaV1;
}

Members

component

component: Type<unknown>;

description

Optional human/model-facing description of what this component renders.

description?: string;

fallback

fallback?: Type<unknown>;

schema

Optional props contract for this component (Zod/Valibot/ArkType via Standard Schema). Enforced as a MOUNT-READINESS GATE: while a streaming tool call's props do not yet validate against this schema, the element's fallback is shown instead of the real component (sync validation only). Consumers (e.g. client-tools) also read it to advertise the component to a model and to validate incoming props.