@@ -12,8 +12,6 @@ to tell you when an element enters or leaves the viewport. Contains both a
1212[ Hooks] ( #useinview-hook ) , [ render props] ( #render-props ) and
1313[ plain children] ( #plain-children ) implementation.
1414
15- ** Storybook Demo:**
16- [ https://react-intersection-observer.vercel.app ] ( https://react-intersection-observer.vercel.app )
1715
1816## Features
1917
@@ -32,13 +30,7 @@ to tell you when an element enters or leaves the viewport. Contains both a
3230
3331## Installation
3432
35- Install using [ Yarn] ( https://yarnpkg.com ) :
36-
37- ``` sh
38- yarn add react-intersection-observer
39- ```
40-
41- or NPM:
33+ Install the package with your package manager of choice:
4234
4335``` sh
4436npm install react-intersection-observer --save
@@ -82,8 +74,6 @@ const Component = () => {
8274};
8375```
8476
85- [ ![ Edit useInView] ( https://codesandbox.io/static/img/play-codesandbox.svg )] ( https://codesandbox.io/s/useinview-ud2vo?fontsize=14&hidenavigation=1&theme=dark )
86-
8777### Render props
8878
8979To use the ` <InView> ` component, you pass it a function. It will be called
@@ -113,8 +103,6 @@ const Component = () => (
113103export default Component ;
114104```
115105
116- [ ![ Edit InView render props] ( https://codesandbox.io/static/img/play-codesandbox.svg )] ( https://codesandbox.io/s/inview-render-props-hvhcb?fontsize=14&hidenavigation=1&theme=dark )
117-
118106### Plain children
119107
120108You can pass any element to the ` <InView /> ` , and it will handle creating the
@@ -134,8 +122,6 @@ const Component = () => (
134122export default Component ;
135123```
136124
137- [ ![ Edit InView plain children] ( https://codesandbox.io/static/img/play-codesandbox.svg )] ( https://codesandbox.io/s/inview-plain-children-vv51y?fontsize=14&hidenavigation=1&theme=dark )
138-
139125> ** Note** <br > When rendering a plain child, make sure you keep your HTML output
140126> semantic. Change the ` as ` to match the context, and add a ` className ` to style
141127> the ` <InView /> ` . The component does not support Ref Forwarding, so if you
0 commit comments