TarekRaafat / autoComplete.js

Simple autocomplete pure vanilla Javascript library.
https://tarekraafat.github.io/autoComplete.js
Apache License 2.0
3.93k stars 236 forks source link

data.src never fires #371

Open PandaWood opened 1 year ago

PandaWood commented 1 year ago

I can't get the autocomplete to populate, I know it's something stupid I must be doing. Following the demo code, I'm especially wondering why doesn't this code print 'getting data' You can assume the id is correct, the js/css is loaded and the control looks exactly right, but what does the data.src need to fire?

console.log('starting autcomplete')

const activityList = new autoComplete({
    selector: '#activity-input',
    data: {
        src: async () => {
            console.log('getting data')  // this never runs, no code in here ever runs, what am I missing?
        }
    }
})
folknor commented 1 year ago

I think we need to see more of your code.