typeahead. Allow funtction as displayKey.

This commit is contained in:
Artem Kozlov
2015-08-31 10:42:56 +02:00
parent c0fe9460e7
commit a568ce9345

View File

@@ -119,8 +119,8 @@ declare module Twitter.Typeahead {
* For a given suggestion object, determines the string representation of it.
* This will be used when setting the value of the input control after a suggestion is selected. Can be either a key string or a function that transforms a suggestion object into a string.
* Defaults to value.
*/
displayKey?: string;
*/
displayKey?: string | ((obj: any) => string);
/**
* A hash of templates to be used when rendering the dataset.