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
I'm using the onkeyup event handler of the input field itself to set the data. But I'm not actually sure this is better than the onInput option, I've seen this only just now.
document.getElementById("myInputField").addEventListener("keyup",function(event){constval=this.value;// Get the data from AJAX, IndexedDb, whatevergetDataFromWhereEver(val).then(function(entries){ac.setData(entries);});});
Is there any better option to use JSON to recive data from other file ?
const
ac = new Autocomplete(field, {onInput:
function () {dane=AJAX();
ac.setData(dane);},
data:[{label: "Text formatu JSON", value: 42}], .....
The text was updated successfully, but these errors were encountered: