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
@suwey using bootstrap3-typeahead.js + tagsinput. I've added/edited the code to reflect what you've given, but I get an error:
Uncaught ReferenceError: typeaheadService is not defined
Searching through boostrap3-typeahead.js or tagsinput.js OR even typeahead.bundle.js, I don't find refernce to typeaheadService.
@w3geekery sorry about that. " typeaheadService.mapArray(options.init.source, options.init.sourceKey);" is my own code in project, you may test it like below:
when use with tagsinput, typeahead will copy the value selected to element.val()
select: function () {
var val = this.$menu.find('.active').data('value');
this.$element.data('active', val);
if(this.autoSelect || val) {
var newVal = this.updater(val);
this.$element
.val('') //change this.displayText(newVal) || newVal => ''
.change();
this.afterSelect(newVal);
}
return this.hide();
},
then tagsinput will have a span and a value in the input
The text was updated successfully, but these errors were encountered: