[Feature Request] Built-in copy/export utility for rendered UI (markdown parity)
Hey team
First off, love what you've built here.
Context
I recently migrated my app from markdown-based LLM responses to json-render generative ui for better UX. One thing I'm missing though is copy portability.
With markdown, users could copy a response and paste it anywhere — docs, email, Slack — and it would still be readable and structured.
With generative UI, the same action gives them the raw JSON spec, which isn't meaningful outside the app.
Example
Prompt: "Give me a list of 5 users"
- Rendered: A beautiful Table component ✨
- Copied: The raw JSON spec
What I've Tried
- Asking the LLM to return both a
uispec and amarkdowntwin (works but costs extra tokens) - DOM serialization via
outerHTML(only works in rich text editors) - Manual text derivation from the JSON (lossy and app-specific)
Question
Is there a recommended pattern for this I might have missed? If not, would something like a toMarkdown(spec) utility or a <CopyButton /> component be something the team would consider?
Happy to contribute if there's interest — just wanted to check in before going down a custom path. Thanks so much!
Source: vercel-labs/json-render