Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
@skava/ui / src / components / molecules / SelectDropDown / Select / renderProps.tsx
Size: Mime:
import { OptionType } from '../typings'
import { SelectProps } from './typings'
import { SelectableState } from 'src/state/SelectionState'

export function renderList(props: SelectProps, state: SelectableState) {
  console.debug('[Select] defaultRenderList', props.list)

  function toItemWithState(item: OptionType, index: number) {
    return props.renderItem(item, props, state)
  }
  return props.list.map(toItemWithState)
}