Commit f451153
docs: in react hooks example, limit createEmpty calls (facebookarchive#2432)
Summary:
In the React hooks example, `EditorState.createEmpty` will be called each time the component is rendered. By wrapping it in a function, it will only be called once per instance of the MyEditor component.
Pull Request resolved: facebookarchive#2432
Reviewed By: claudiopro
Differential Revision: D21652207
Pulled By: mrkev
fbshipit-source-id: 0c24a4e84718227b4e89d1c810b2558ffd51384d1 parent 2660a3b commit f451153
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
75 | 75 | | |
76 | 76 | | |
77 | 77 | | |
78 | | - | |
| 78 | + | |
79 | 79 | | |
80 | 80 | | |
81 | 81 | | |
| |||
0 commit comments