useImperativeHandle
Loading "useImperativeHandle"
Run locally for transcripts
π¨βπΌ We've got a new thing for you to work on.
π§ββοΈ I've put together a
Scrollable
component which is a wrapper around a div
that has a way to scroll to the top and bottom of the content. We want to be
able to add buttons to the App
that will allow users to scroll to the top and
bottom of the content when clicked.π¨βπΌ So we need you to
useImperativeHandle
to expose a scrollToTop
and
scrollToBottom
method from the Scrollable
component. These methods are
already implemented, you just need to expose them.