npm.io
0.2.1 • Published 7 years ago

node-fist

Licence
MIT
Version
0.2.1
Deps
0
Size
8 kB
Vulns
0
Weekly
0
Stars
4

node-fist

Node.js client library for Fist full text search

Installation

npm install node-fist

Support and Requirements

Only the LTS and Current Node.js versions are supported. Other versions may work, but are not actively tested.

Usage
Connecting
const { FistConnection } = require('node-fist')

const index = new FistConnection('localhost', 5575)
Indexing
index.index('doc_1', 'the quick brown fox jumped over the lazy dog')
Searching
index.search('lazy dog', (err, documents) => {
  if (err) return console.error(err)
  console.log(documents) // => ['doc_1']
})
Disconnecting
index.close()
License

Released under the terms of the MIT license. See LICENSE for more details.

Keywords