SelectAsyncProps interface

Signature

  1. export interface SelectAsyncProps<T>

Import

  1. import { SelectAsyncProps } from '@grafana/ui';

Properties

PropertyTypeDescription
cacheOptionsbooleanIf cacheOptions is true, then the loaded data will be cached. The cache will remain until cacheOptions changes value.
defaultOptionsboolean | Array<SelectableValue<T>>When specified as boolean the loadOptions will execute when component is mounted
loadingMessagestringMessage to display when options are loading
loadOptions(query: string, cb?: LoadOptionsCallback<T>) => Promise<Array<SelectableValue<T>>> | voidAsynchronously load select options

cacheOptions property

If cacheOptions is true, then the loaded data will be cached. The cache will remain until cacheOptions changes value.

Signature

  1. cacheOptions?: boolean;

defaultOptions property

When specified as boolean the loadOptions will execute when component is mounted

Signature

  1. defaultOptions?: boolean | Array<SelectableValue<T>>;

loadingMessage property

Message to display when options are loading

Signature

  1. loadingMessage?: string;

loadOptions property

Asynchronously load select options

Signature

  1. loadOptions?: (query: string, cb?: LoadOptionsCallback<T>) => Promise<Array<SelectableValue<T>>> | void;