This is the JavaScript library for Merlin Search.
npm install merlin.jsvar Blackbird = require('merlin.js');<script src="merlin.js"></script>For usage examples, see the Search API documentation.
var engine = Blackbird.engine({
company: 'company_name',
environment: 'environment_name',
instance: 'instance_name'
});
engine.search({ q: 'dress' })
.end(function (e, r) {
console.log(r.body.results.numfound);
});Clone the repo, then run the following:
cd merlin.js
npm installBuilding compiles the es5 JavaScript and the webpacked merlin.js
npm run buildnpm test