Answers for "react dropdown menu stack overflow"

0

react dropdown menu stack overflow

var Select = require('react-select');

var options = [
  { value: 'one', label: 'One' },
  { value: 'two', label: 'Two' }
];

function logChange(val) {
  console.log("Selected: " + JSON.stringify(val));
}

<Select
  name="form-field-name"
  value="one"
  options={options}
  onChange={logChange}
/>
Posted by: Guest on March-05-2020

Code answers related to "Javascript"

Browse Popular Code Answers by Language