npm.io
2.0.2 • Published 3 years ago

@devspeed/filterjs

Licence
MIT
Version
2.0.2
Deps
0
Size
23 kB
Vulns
0
Weekly
0

Get started

based on the older package devspeed-filterjs

const {Filter, badwords} = require("@devspeed/filterjs");

const TextFilter = new Filter("hi badword") 

console.log(TextFilter.censor()) // hi *******

console.log(TextFilter.hasBlacklistWord()); // true

badwords is filled with most of the words from https://www.noswearing.com

Keywords