Skip to content

Commit 3b6a4f9

Browse files
committed
<ParallaxProvider> usage clarifications #9
1 parent 47f0edb commit 3b6a4f9

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,17 +21,17 @@ npm i react-scroll-parallax --save
2121

2222
## Usage
2323

24-
Wrap your component tree that will contain `<Parallax />` components with the `<ParallaxProvider />`. For example:
24+
The `<ParallaxProvider />` should wrap the component tree that contains all `<Parallax />` components. This should be a top level component like `<AppContainer />`. The `<ParallaxProvider />` will then provide necessary context to the [`parallaxController`](#parallax-controller-context) for all `<Parallax />` elements. For example:
2525

2626
```jsx
2727
...
2828
import { ParallaxProvider } from 'react-scroll-parallax';
2929

30-
class App extends Component {
30+
class AppContainer extends Component {
3131
render() {
3232
return (
3333
<ParallaxProvider>
34-
<StuffWithParallax />
34+
<App />
3535
</ParallaxProvider>
3636
);
3737
}

0 commit comments

Comments
 (0)