AsyncChoicesInterfaceTypescript Type

Source
import type { AsyncChoicesInterface } from "@prestojs/viewmodel";
AsyncChoicesInterface<ItemType,ValueType>

API

Methods

getChoices(items)

Arguments:

ArgumentTypeDescription
*itemsItemType[]
Returns:(|[string, []])[]
getLabel(item)

Arguments:

ArgumentTypeDescription
*itemItemType
Returns:ReactNode
getMissingLabel(value)

Arguments:

ArgumentTypeDescription
*valueValueType
Returns:ReactNode
getValue(item)

Arguments:

ArgumentTypeDescription
*itemItemType
Returns:ValueType
list(params)

Arguments:

ArgumentTypeDescription
*paramsRecord
Returns:Promise
parseValue(value)

Arguments:

ArgumentTypeDescription
*valueany
Returns:ValueType
retrieve(value,?deps)

Arguments:

ArgumentTypeDescription
*valueValueType|ValueType[]
depsany
Returns:Promise
useListProps(args)

Arguments:

ArgumentTypeDescription
*argsany
Returns:any
useResolveItems<T>(item)

Arguments:

ArgumentTypeDescription
*itemT
Returns:T
useRetrieveProps(args)

Arguments:

ArgumentTypeDescription
*argsany
Returns:any

Properties

multiple

Source
boolean