Programmatically triggering typeahead.js result display

后端 未结 17 1843
余生分开走
余生分开走 2020-11-30 05:01

I am using Twitter\'s typeahead.js (https://github.com/twitter/typeahead.js/) on an input field which is pre filled from a query string. After loading the page, i\'d like to

17条回答
  •  一整个雨季
    2020-11-30 05:10

    I took a look at the source code and found this undocumented way:

    var $myinput = $('#myinput');
    $myinput.data('typeahead')._showDropdown()
    

提交回复
热议问题