ndx-utils
v1.0.0-beta.0
Published
Utility functions for a lightweight full-text searching and indexing library ndx.
Downloads
9
Readme
ndx ·
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;