Have you read the Contributing Guidelines on issues?
Prerequisites
Description
If react-live LivePreview is re-rendered, it will peform preview from the LiveProvider code prop instead of the current state of the content.
I fixed this in something similar using theLiveEditor onChange prop, to keep state of the current code being edited, and passing that state to the LiveProvider instead of the original code.
Reproducible demo
No response
Steps to reproduce
- Go to https://docusaurus.io/docs/markdown-features/code-blocks#interactive-code-editor
- Add some text after the period in the output
- Change the theme
Expected behavior
The newly edited code is used for the preview
Actual behavior
The original code is used for the preview until a subsequent edit
Your environment
No response
Self-service