import React from 'react'; const VIEW = 'VIEW'; const LOGOUT = 'LOGOUT'; class NavBar extends React.Component { constructor (props) { super(props); this.state = { selectedOption: '', } this.handleSelection = this.handleSelection.bind(this); } componentDidMount () { // set first selected option } handleSelection (event) { const value = event.target.selectedOptions[0].value; switch (value) { case 'logout': break; case 'view': break; default: break; } } render () { return (
); } } export default NavBar;