Bug: <select size value>
with value
not matching any option
results in first option being selected
#24469
Labels
Component: DOM
Status: Unconfirmed
A potential issue that we haven't yet confirmed as a bug
Type: Bug
React version: 18.1.0, 17.0.2
Steps To Reproduce
<select value="not-an-option" size="2"><option value="an-option">one</option></select>
Link to code example: https://codesandbox.io/s/react-18-select-value-with-value-not-matching-option-wopmt9?file=/src/index.js
The current behavior
The first option will be marked as selected
The expected behavior
No option should be selected
#10691 was asking for a warning.
The text was updated successfully, but these errors were encountered: