meteor-typeahead icon indicating copy to clipboard operation
meteor-typeahead copied to clipboard

Can't get the server side search sample to work

Open derwaldgeist opened this issue 8 years ago • 4 comments

When the page loads, exactly one call to the search handler is being made -- but an invalid one with all parameters set to undefined. This happens even without any user input.

If I then enter something into the field, nothing happens. It seems as if the event handlers are broken.

derwaldgeist avatar Oct 26 '15 18:10 derwaldgeist

+1. I just noticed this has stopped working in my application. Downgrading doesn't seem to help. Is this related to Meteor v1.2?

davidworkman9 avatar Oct 26 '15 18:10 davidworkman9

same problem

yegorov-p avatar Nov 13 '15 09:11 yegorov-p

And found the solution. According to https://github.com/sergeyt/meteor-typeahead/issues/121 event names were synced with typeahead docs, so you should use data-select="selected" instead of data-selected="selected"

yegorov-p avatar Nov 13 '15 09:11 yegorov-p

FYI you also need to define Meteor.methods on client side. Meteor generates internal stubs for them in order to RPC them.

sergeyt avatar Nov 13 '15 17:11 sergeyt