DEV Community

Abu2505
Abu2505

Posted on Edited on

Multiselect Dropdown bind in react Js

Can you please help me, someone, how to bind multiselect dropdown value in react js
const options = [
{ label: 'Item 1', value: 1, description:"Item description 1"},
{ label: 'Item 2', value: 2, description:"Item description 2"},
{ label: 'Item 3', value: 3, description:"Item description 3"},
{ label: 'Item 4', value: 4, description:"Item description 4"}
];

//Class Component
constructor(props) {
super(props)
this.state = {
currentStep: 1,

selectedoptions: []
}
}
handleChange = event => {
const {name, value} = event.target
this.setState({
[name]: value
})

}

function Step1(props) {
if (props.currentStep !== 1) {
return null
}
return(










                  </td>                      
              </tr>
          </tbody>
      </table>   
    </div>
  </React.Fragment>

);
}

Top comments (0)