-
Notifications
You must be signed in to change notification settings - Fork 47.2k
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
HTML Select Option Can't Handle React Child Node #14903
Comments
I think the
-https://developer.mozilla.org/en-US/docs/Web/HTML/Element/option
-https://www.w3.org/TR/html52/sec-forms.html#the-option-element
-https://jsfiddle.net/mdjasper/d5yxcgk4/3/ This is implemented in React Dom
|
@mdjasper This is what the spec says. I don't see any release notes mentioning that they were deprecating this though? |
A colleague has found this: #13465 Apparently working as designed. |
This "works" in React 18: https://jsfiddle.net/ce6yo17w/1/ Aside from that putting |
Do you want to request a feature or report a bug?
Bug
What is the current behavior?
The Option component used for HTML Select can no longer support React Nodes as a child.
Fiddle of problem
https://jsfiddle.net/83hr5smv/
What is the expected behavior?
The select would display the option label using the wrapped React node.
Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React?
I tried to upgrade to v16.6.3 when I found this problem. Last known working version was v16.2.0. I haven't investigated between 16.2.0 and 16.6.3, but I did confirm this is still a problem on the latest stable v16.8.2.
The text was updated successfully, but these errors were encountered: