Skip to content

bobbylkchao/bloodhound

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

bloodhound-js

Continue to maintain bloodhound and avoid vulnerability issues.

bloodhound.js for node and browser

Bloodhound is the typeahead.js suggestion engine. Bloodhound is robust, flexible, and offers advanced functionalities such as prefetching, intelligent caching, fast lookups, and backfilling with remote data.

Installtion

npm install bloodhound-js --save

Changes

Usage

var Bloodhound = require('bloodhound-js');
var engine = new Bloodhound({
  local: ['dog', 'pig', 'moose'],
  queryTokenizer: Bloodhound.tokenizers.whitespace,
  datumTokenizer: Bloodhound.tokenizers.whitespace
});

var promise = engine.initialize();

promise.then(function() {
  console.log('engine init done');

  engine.search(
    'd',
    function(d) {
      console.log(d);
    },
    function(d) {
      console.log(d);
    }
  );
});

License

MIT

About

Continue to maintain bloodhound and avoid vulnerability issues.

Resources

License

Stars

Watchers

Forks

Packages

No packages published