react-live
react-live copied to clipboard
Add the ability to use custom LiveError component.
Is there an existing issue for this?
- [x] I have searched the existing issues
Code of Conduct
- [x] I agree to follow this project's Code of Conduct
Feature Request
Hi there!
I'm working on a generative UI concept powered by an LLM-based code generator, where the UI components are dynamically generated through LLM outputs.
Since the code is AI-generated, it occasionally contains errors or incomplete implementations. I'd like to integrate a custom LiveError component that can handle these errors gracefully and trigger logic to automatically re-fetch or regenerate the component code when an error occurs.
I believe this would improve the resilience of the live editing experience in LLM-driven workflows.
Would you be open to adding support for this feature? I'd be happy to contribute with a PR if you're on board!
Thanks so much for your work!
Not sure this is a workaround or your intention, but for now I'm importing LiveContext and creating a component myself. Probably good to document or change to recieve callbacks onError and/or children ? Thanks