-
Notifications
You must be signed in to change notification settings - Fork 20
Closed
Labels
Description
Right now React-Scroll-To only supports scrolling on the window, but there are use-cases where a user might want to scroll inside different containers (say a div).
Proposed Idea:
Add a new prop to <ScrollTo> to accept a 'scrolling location'. This would look like:
<ScrollTo container={divRef}>
{scroll => ... }
</ScrollTo>Where the container could be a Ref passed in. If nothing is given in the container prop, default to using window.
jikkujose, newyork-anthonyng and damassi