typeahead: Don't call html with a jquery object.

This is helpful beyond appeasing the linter, because TypeScript only
[permits](https://unpkg.com/browse/@types/jquery@3.5.29/JQuery.d.ts#L5287)
`.html(…)` to accept a `string` or `HTMLElement` argument (or
function returning those), not JQuery. The behavior with a JQuery
argument is also [undocumented](https://api.jquery.com/html/#html2).
This commit is contained in:
evykassirer 2024-03-10 11:54:53 -07:00 committed by Tim Abbott
parent 2140138f5e
commit 30ecf6fafd
1 changed files with 1 additions and 1 deletions

View File

@ -359,7 +359,7 @@ Typeahead.prototype = {
});
$items.first().addClass("active");
this.$menu.html($items);
this.$menu.empty().append($items);
return this;
},