example/Example.js
function LI(props) {
  return (
    <MenuItem
      style={{cursor: 'pointer', userSelect: 'none'}}
      highlightedStyle={{background: 'gray'}}
      onItemChosen={e => {
        console.log(`selected ${props.children}, byKeyboard: ${String(e.byKeyboard)}`);
      }}
      {...props}
    />
  );
}
function LI(props) {
  return (
    <MenuItem
      style={{cursor: 'pointer', userSelect: 'none'}}
      highlightedStyle={{background: 'gray'}}
      onItemChosen={e => {
        console.log(`selected ${props.children}, byKeyboard: ${String(e.byKeyboard)}`);
      }}
      {...props}
    />
  );
}
function LI ( props ) { return ( < MenuItem style = { { cursor : 'pointer' , userSelect : 'none' } } highlightedStyle = { { background : 'gray' } } onItemChosen = { e => { console . log ( ` ${ props . children } ${ String ( e . byKeyboard ) } ` ) ; } } { ... props } / > ) ; }
MenuItems don't come with any styling by default! You'll probably want to make your own component which wraps them and adds your own application's style to them like this.
MenuItems don t come with any styling by default! You ll probably want to make your own component which wraps them and adds your own application s style to them like this .