MCPcopy
hub / github.com/thesysdev/openui / defineComponent

Function defineComponent

packages/react-lang/src/library.ts:40–47  ·  view source on GitHub ↗
(config: {
  name: string;
  props: T;
  description: string;
  component: ComponentRenderer<z.infer<T>>;
})

Source from the content-addressed store, hash-verified

38// ─── defineComponent (React) ────────────────────────────────────────────────
39
40export function defineComponent<T extends $ZodObject>(config: {
41 name: string;
42 props: T;
43 description: string;
44 component: ComponentRenderer<z.infer<T>>;
45}): DefinedComponent<T> {
46 return coreDefineComponent<T, ComponentRenderer<z.infer<T>>>(config);
47}
48
49// ─── createLibrary (React) ──────────────────────────────────────────────────
50

Callers 15

BentoItem.tsxFile · 0.90
SurveyRating.tsxFile · 0.90
Section.tsxFile · 0.90
Markdown.tsxFile · 0.90
ImageGrid.tsxFile · 0.90
Button.tsxFile · 0.90
FooterCentered.tsxFile · 0.90
Article.tsxFile · 0.90
ListItem.tsxFile · 0.90
Avatar.tsxFile · 0.90
NavLink.tsxFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected