Skip to content

Commit eae26be

Browse files
bennettdamsjdecked
authored andcommitted
Add import statements for hooks-example in README (facebookarchive#2075)
Summary: **Summary** The README is missing the import statements for the getting-started-example with hooks. Pull Request resolved: facebookarchive#2075 Differential Revision: D15415655 Pulled By: claudiopro fbshipit-source-id: 64c5b766e381269ebf441ac98b79260354f1d198
1 parent 2d43f95 commit eae26be

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,10 @@ Since the release of React 16.8, you can use [Hooks](https://reactjs.org/docs/ho
9595

9696

9797
```js
98+
import React from 'react';
99+
import ReactDOM from 'react-dom';
100+
import {Editor, EditorState} from 'draft-js';
101+
98102
function MyEditor() {
99103
const [editorState, setEditorState] = React.useState(
100104
EditorState.createEmpty()

0 commit comments

Comments
 (0)