0.1.1 • Published 4 years ago
strsearch2regexp v0.1.1
strsearch2regexp
Converts a search string to a unicode regexp with character variants (e.g. "foo bar" -> "foöó.*baäár")
This code is far from complete. Pull requests are very welcome!
Installation
npm add --save strsearch2regexp
Usage
const strsearch2regexp = require('strsearch2regexp')
console.log(strsearch2regexp('foo bar'))
// f[oòóôõöø]o.*b[aàáâãäå]r