File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -17,7 +17,8 @@ Each component lives in [`components/tool-ui/`](https://github.com/assistant-ui/
1717- ` schema.ts ` : Serializable schema + strict/safe parsers (` SerializableXSchema ` , ` parseSerializableX ` , ` safeParseSerializableX ` )
1818- ` types.ts ` (optional): TypeScript type definitions when component complexity justifies a dedicated file
1919- ` component-name.tsx ` : Main component implementation
20- - ` index.ts ` or ` index.tsx ` : Public exports (component, types, parser)
20+ - ` index.ts ` or ` index.tsx ` : Public UI exports only (component + UI-facing types)
21+ - ` <component>/schema ` entrypoint: import schema values and parse helpers from this path (not from the main index)
2122
2223### Sub-Components (as needed)
2324
@@ -73,7 +74,7 @@ Implementation pattern:
7374 - Minimal but clear chrome
74755 . Sub-components: Extract header/body/footer/actions when the component grows
75766 . ` context.tsx ` : Use React context only when sub-components genuinely need shared state
76- 7 . ` index.tsx ` : Export the public API (component, types, strict/safe parsers)
77+ 7 . ` index.tsx ` : Export only the UI surface (component + UI-facing types); export strict/safe parsers from ` .../schema `
7778
7879</Step >
7980
You can’t perform that action at this time.
0 commit comments