commonform-phrase-annotator
The module exports a single function that takes an array of strings and a function for generating annotations, returning an annotator function to apply to Common Forms.
var phrases = 'thereof' 'whereof'
The annotation function receives the form in which a string was found, its path within the overall form, and the string that matches. It must return a Common Form Annotations.
{ return message: '"' + string + '" is archaic' path: path source: 'example-annotator' url: null } var phraseAnnotator = var annotator =
The library does the job of finding matches and calculating paths.
var assert = assert