Closed rockmandash closed 6 years ago
You can wrap the withViewport
HOC into your custom one.
const withMyViewport = (Comp) => withViewport(Comp, 'visible', {threshold: 0.25});
And then use your new HOC.
export default compose(withMyViewport, withRouter)(MyComponent)
Hope that woks.
@streamich for your reply!
Hello, thank you for this amazing library. I have a component like this
Normaly with HOCs I will do this
But I have
threshold
parameters! How do I pass in? Thank you!