Yelp / lemon-reset

Consistent, cross-browser React DOM tags, powered by CSS Modules. 🍋
MIT License
131 stars 13 forks source link

Consider using the new ref forwading API #45

Open magicmark opened 6 years ago

magicmark commented 6 years ago

Currently, we use tagRef to pass along a ref to the actual underlying DOM element https://github.com/Yelp/lemon-reset/blob/b55997c667857941bd023d7225b6931368e6f1fb/README.md#L48

Looks like there's a new API to address just this though: https://reactjs.org/docs/forwarding-refs.html

it can be useful for some kinds of components, especially in reusable component libraries

Sounds like us :P

mxmul commented 5 years ago

Let's implement this, and get rid of the tagRef prop in a v2 release.

mxmul commented 2 months ago

consider using ref: https://react.dev/blog/2024/04/25/react-19#ref-as-a-prop