You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using typeahead 0.11.1 on a website and making a remote call to the public API for search.
I noticed that typeahead works fine when there are more than limit records ( default limit is 5 as you guys have set it ) but when API returns less than 5 results. typeahead just shows 1 single result there.
"Algolia autocomplete" (but creates a form element, so not usable within existing forms, only as a standalone element): https://github.com/algolia/autocomplete
I'm using typeahead 0.11.1 on a website and making a remote call to the public API for search.
I noticed that typeahead works fine when there are more than limit records ( default limit is 5 as you guys have set it ) but when API returns less than 5 results. typeahead just shows 1 single result there.
I noticed there was a similar kind of issue earlier link here
https://stackoverflow.com/questions/31007825/bootstrap-typeahead-not-showing-hints-as-expected
and after checking the
typeahead.bundle.js
I found the suggested solution is implemented. But this solution isn't working in the latest release.I noticed the issue is being the number of results returned by the API.
So on LINE 1723
I changed the following code
rendered += suggestions.length;
To
if(suggestions.length > that.limit) rendered += suggestions.length;
and this fixed the issue for me. I haven't tested it much yet will report if found anything.
thanks
The text was updated successfully, but these errors were encountered: