Does twitter bootstrap typeahead support a remote data source?

Does typeahead support a remote data source in version 2.0.3 of twitter-bootstrap?

Typehead function reference http://twitter.github.com/bootstrap/javascript.html#typeahead

+5
source share
1 answer

Have you tried:

$('.typeahead').typeahead({
    source: function (query, typeahead) {
        return $.post('/typeahead', { query: query }, function (data) {
            return typeahead.process(data);
        });
    }
});
+4
source

All Articles