Comments (5)
Added a method to directly show suggestions
https://bootstrap-autocomplete.readthedocs.io/en/latest/#show-autocomplete
from bootstrap-autocomplete.
I have a similar use-case, but my option is when there is nothing in there and the user hits a 'search' button. It would do a similar thing to what you wanted, but search on nothing - ie deliver all the results in the dropdown.
Sometimes the user knows what they want and can type in the start, sometimes they don't and need to 'browse' the options.
from bootstrap-autocomplete.
You must provide an initial item list.
This is how to customize the resolver to match your use-case.
https://jsfiddle.net/k4n37026/5/
The custom resolver can use the offline list when qry is empty and fetch the list from server when the user types in some values.
@dipsylala and @fberasategui could you please check if this solution fits your case?
Perhaps I could implement a method to programmatically show dropdown but you still need to provide the initial item list.
from bootstrap-autocomplete.
@xcash in my case, I would send the empty query to the server and handle the case server-side (showing first X results, but without filtering, for example)
from bootstrap-autocomplete.
from bootstrap-autocomplete.
Related Issues (20)
- TAB keyup should be ignored/not trigger ajax request & dropdown HOT 3
- Cancel dropdown when field has lost focus HOT 3
- How to import into webpack build? HOT 2
- Custom header / footer options?
- Uncaught TypeError: this._dd is undefined HOT 1
- Select not populating HOT 5
- Idea needed
- "dropdown-item" css class is used for Bootstrap 3, which is not there
- How to throttling with custom resolvers
- Cross Domain Option HOT 1
- Unable to reset the autocomplete HOT 2
- Wrongly written documentation title
- Limit number of entries in the dropdown list HOT 2
- Bootstrap 5 support HOT 1
- Pagination
- How to force input from suggestions
- Dropup enhancement request
- Crash when XHR request fails and no fail handler is defined HOT 1
- "Searching" indicator
- Different Options and Display Text in Bootstrap Select Dropdowns
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bootstrap-autocomplete.