javascript - Select2 Custom Matcher for Non-Adjacent Keywords -


I use in my app to allow for a dropdown search with 1200 options

I am currently using the default implementation of Select2, which are adjacent to search results, until the keywords are imminent:

  function (word, text) {Return Text.toUpperCase () IndexOf (term.toUpperCase ())> gt; = 0; }  

For example, 'Stackworflow Question' returns the option of 'Stackoverflow Question' about 'Return Option'

I still like results based on non- I will return - For the small keywords, for example, I also like that the above option will be returned when searching for 'Stackoverflow Selection 2'.

Does anyone have the idea of ​​creating custom matures for this idea?

<
"

, select2 stack overflow , stack overflow selection 2 question , question About Selection 2

  & lt; Select Id = "e17_2" style = "width: 300px" & gt; Option alt = "About selection 2 Stackoverflow question "& gt; stack overflow question about selection 2 & lt; / option & gt; & lt; option alt =" stackoverflow other line ... "& gt; stackoverflow other line ... & lt; / options Copied from & gt; & lt; / select & gt;  

:

  Function permits ( Input, paragraph, used chairs) {var i, for ch; (i = 0; i  

Comments

Popular posts from this blog

java - org.apache.http.ProtocolException: Target host is not specified -

java - Gradle dependencies: compile project by relative path -

ruby on rails - Object doesn't support #inspect when used with .include -