1.0.0-beta.0 • Published 5 years ago

ndx-utils v1.0.0-beta.0

Weekly downloads
2
License
MIT
Repository
github
Last release
5 years ago

ndx · GitHub license npm version codecov CircleCI Status PRs Welcome

Utility functions for a lightweight javascript (TypeScript) full-text indexing and searching library ndx.

API

Tokenizers

Whitspace Tokenizer

The whitespace tokenizer breaks on whitespace - spaces, tabs, line feeds and assumes that contiguous nonwhitespace characters form a single token.

function whitespaceTokenizer(s: string): string[];

Filters

LowerCase Filter

Converts term to lower case.

function lowerCaseFilter(term: string): string;

Trim Non-Word Characters Filter

Removes all non-word characters at the start and at the end of the term.

function trimNonWordCharactersFilter(term: string): string;
1.0.0-beta.0

5 years ago