Skip to content

FuzzySuggestModal.renderSuggestion method

FuzzySuggestModal › renderSuggestion

Official

Render the suggestion.

Signature:

renderSuggestion(item: FuzzyMatch<T>, el: HTMLElement): void

Parameters:

ParameterTypeDescription
itemFuzzyMatch<T>The match.
elHTMLElementThe element to render into.

Returns: void

Since: 0.9.20

Example:

class MyFuzzySuggestModal extends FuzzySuggestModal<string> {
public override renderSuggestion(item: FuzzyMatch<string>, el: HTMLElement): void {
el.createEl('strong', { text: item.item });
}
}