Add new example wit deconstructed argument

This commit is contained in:
arichter83
2018-12-17 12:47:11 +01:00
parent 9786a8c8e4
commit 0b98134ca5
@@ -36,13 +36,21 @@ class BasicExample extends React.Component {
filterBy={(option, props) => (props.text.indexOf(option) !== -1) }
placeholder="Choose a state..."
/>
<Typeahead
labelKey="name"
multiple={multiple}
options={options}
maxHeight='300px'
filterBy={(option, {text}) => (text.indexOf(option) !== -1) }
placeholder="Choose a state..."
/>
<Typeahead
labelKey="name"
options={options}
placeholder="Choose a state..."
renderMenuItemChildren={ (option, props, index) =>
<Highlighter key="name" search={props.text}>
{option.name}
{option.name} {index}
</Highlighter>
}
/>