import MEditor from '@monaco-editor/react'; import React from 'react'; function Editor({ value }: EditorProps): JSX.Element { return ( { if (value.current && newValue) { // eslint-disable-next-line no-param-reassign value.current = newValue; } }} /> ); } interface EditorProps { value: React.MutableRefObject; } export default Editor;