mirror of
https://github.com/facebook/react.git
synced 2025-11-01 09:12:30 +00:00
Merge pull request #2007 from janhancic/better-docs-for-select-multiple
Add a 'note' about passing arrays into the `value` attribute
This commit is contained in:
@@ -145,3 +145,7 @@ The selected `<option>` in an HTML `<select>` is normally specified through that
|
||||
```
|
||||
|
||||
To make an uncontrolled component, `defaultValue` is used instead.
|
||||
|
||||
> Note:
|
||||
>
|
||||
> You can pass an array into the `value` attribute, allowing you to select multiple options in a `select` tag: `<select multiple={true} value={['B', 'C']}>`.
|
||||
|
||||
Reference in New Issue
Block a user