From 6608a5df392c599c21d48fc88ee57eba60968dee Mon Sep 17 00:00:00 2001 From: Marton Langa Date: Thu, 28 Nov 2019 23:21:12 +0100 Subject: [PATCH] Remove controlled value state (#3153) --- docs/walkthroughs/05-executing-commands.md | 3 --- 1 file changed, 3 deletions(-) diff --git a/docs/walkthroughs/05-executing-commands.md b/docs/walkthroughs/05-executing-commands.md index 7110fb03e..59c258cb3 100644 --- a/docs/walkthroughs/05-executing-commands.md +++ b/docs/walkthroughs/05-executing-commands.md @@ -250,7 +250,6 @@ Now our commands are clearly defined and you can invoke them from anywhere we ha ```js const App = () => { - const [value, setValue] = useState(initialValue) const editor = useMemo(() => withCustom(withReact(createEditor())), []) const renderElement = useCallback(props => { switch (props.element.type) { @@ -292,10 +291,8 @@ const App = () => { setValue(newValue)} onKeyDown={event => { if (!event.ctrlKey) { return