This is a feature request for a disabled flag on <LiveProvider> like react-live has (doc).
The goal is to allow someone to make the editor read-only:
const isEnabled = someLogicThatChecksIfEditorShouldBeEditable;
return (
<LiveProvider code={code} scope={scope} disabled={isEnabled}>
<LivePreview style={{ padding: '10px' }} />
<LiveEditor style={{ minHeight: '100%', fontFamily: 'monospace' }}
<LiveError />
</LiveProvider>
);
This is a feature request for a
disabledflag on<LiveProvider>likereact-livehas (doc).The goal is to allow someone to make the editor read-only: