Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Suggestion]: Since forwardRef is considered a legacy API, it should be removed from another section of the documentation. #7426

Open
Saeed-jlnsi opened this issue Jan 12, 2025 · 1 comment

Comments

@Saeed-jlnsi
Copy link

Saeed-jlnsi commented Jan 12, 2025

Summary

Summary

Since forwardRef is considered a legacy API, it should be removed from Manipulating the DOM with Refs section of the documentation.

Page

https://react.dev/learn/manipulating-the-dom-with-refs#recap

Details

In the recap section is still a reference to forwardRef:

"A component doesn’t expose its DOM nodes by default. You can opt into exposing a DOM node by using forwardRef and passing the second ref argument down to a specific node."

Could be change to : "A component doesn’t expose its DOM nodes by default. You can opt into passing a ref argument like a props down to a specific node."

@lonr
Copy link

lonr commented Jan 16, 2025

Just for your information, the hint and solution for the fourth challenge still make reference to the deprecated forwardRef.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants