Skip to content

Commit d752626

Browse files
committed
Remove react-dom as a peer dep
1 parent e7ac339 commit d752626

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

Readme.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,8 @@ viewport.
1111

1212
`npm install use-is-in-viewport`
1313

14-
This hook declares `react` and `react-dom` as _peer dependencies_. While it does not depend on
15-
`react-dom` itself, hooks can misbehave if the renderer and react version don't match up. Given that
16-
the `IntersectionObserver` is a web platform api, `react-dom` was added as a the renderer peer
17-
dependency.
14+
Please note that this hook declares `react` and as _peer dependency_. Therefore, you must have
15+
`react` installed to use this package.
1816

1917
Please [open as issue](https://github.com/zeusdeux/use-is-in-viewport/issues/new) if this default
2018
causes an issue in your application.

package.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,7 @@
2828
"observe-element-in-viewport": "0.0.11"
2929
},
3030
"peerDependencies": {
31-
"react": "^16.8.6",
32-
"react-dom": "^16.8.6"
31+
"react": "^16.8.6"
3332
},
3433
"engines": {
3534
"node": ">=10"

0 commit comments

Comments
 (0)