How to make a drop down list in react ?

React.js

Nicesnippets

3622

18-03-2020


How to make a drop down list in react ?

Hello Friends,

If you need to see example of react bootstrap dropdown menu example. if you want to see example of react dropdown menu then you are a right place. you can see how to make a drop down list in react. if you want to see example of react dropdown button then you are a right place.

/src/App.js file


import React from 'react';

import './App.css';

import { DropdownButton,Dropdown } from 'react-bootstrap'

function App() {

return (

<div>

<DropdownButton id="dropdown-item-button" title="Dropdown button">

<Dropdown.Item as="button">Action</Dropdown.Item>

<Dropdown.Item as="button">Another action</Dropdown.Item>

<Dropdown.Item as="button">Something else</Dropdown.Item>

</DropdownButton>

</div>

);

}

export default App;

I hope it can help you...