Open luisalmeida12 opened 4 years ago
+1
Console logs nothing when I use (from docs)
jQuery('.typeahead').bind('typeahead:select', function(ev, suggestion) {
console.log('Selection: ' + suggestion);
});
jQuery('.hotel_name').bind('typeahead:select', function(ev, suggestion) {
console.log('Selection: ' + suggestion);
});
Console logs undefined when I try to add in definition:
jQuery('.hotel_name').typeahead({
source: function (query, result) {
jQuery.ajax({ ... });
},
select: function (ev, suggestion) {
console.log('Selection: ' + suggestion);
}
});
What are we missing?
@elzix looks this is not being supported. :/
The events were changed with version 0.11.0. You are probably using an older version. In 0.10.5 typeahead:select is typeahead:selected and typeahead:open is typeahead:opened.
This should be in the documentation, but it would probably be better to switch to a supported fork.
I'm trying to trigger a custom event like:
typeahead:select but nothing happens. my code is listing the info I want but then when i select nothing happens. What am I doing wrong?