Closed SBagaria2710 closed 2 years ago
Hello everyone! Is this a valid bug/enhancement? If so, can I work on this? Thank you :)
Currently forwardRef
is only added to a few complex components, and most of the time you don't have to use ref. In what scenario does the Collapse component need to use ref instead of the original controlled component solution?
This issue has been closed for a long time without activity, please reopen it if there is an update.
Bug report 🐞
Version & Environment
geist-ui/react
: 2.2.0Expected Behaviour
I expected collapse component to have
forwardRef
in place, so it'd pass my ref to the DOM. I don't think it does. I wish to scroll to a particular collapse component within the collapse group. Since, I am not able to attach a ref to it, hence not able to scroll that collapse into view.Actual results (or Errors)
I got an error:
Warning: Function components cannot be given refs. Attempts to access this ref will fail. Did you mean to use React.forwardRef()?