diff --git a/docs/walkthroughs/installation.md b/docs/walkthroughs/installation.md index dbc2aed5..ecdc126e 100644 --- a/docs/walkthroughs/installation.md +++ b/docs/walkthroughs/installation.md @@ -182,7 +182,6 @@ const Editor = () => { // Setup the binding const editor = useMemo(() => { - const sharedType = provider.document.get('content', Y.XmlText); const e = withReact(withYjs(createEditor(), sharedType)); // Ensure editor always has at least 1 valid child @@ -202,6 +201,7 @@ const Editor = () => { { at: [0] } ); }; + return e; }, []); const [value, setValue] = useState([])