Skip to content

Commit 085e7bb

Browse files
Merge pull request transitive-bullshit#172 from izayl/izayl-patch-1
Update readme.md
2 parents 839e2e2 + 1f83e37 commit 085e7bb

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

readme.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,9 @@ npm run deploy
112112

113113
This creates a production build of the example `create-react-app` that showcases your library and then runs `gh-pages` to deploy the resulting bundle.
114114

115+
## Use with React Hooks
116+
117+
If you use [react-hooks](https://reactjs.org/docs/hooks-intro.html) in your project, when you debug you example you may run into a exception [Invalid Hook Call Warning](https://reactjs.org/warnings/invalid-hook-call-warning.html). This [issue](https://github.com/facebook/react/issues/14257) explain the reason, your lib and example use different instance, one solution is rewrite the `react` path in your example `package.json` to 'file:../node_modules/react' or 'link:../node_modules/react'.
115118

116119
## Examples
117120

0 commit comments

Comments
 (0)