1.1.0 • Published 3 years ago

vulgar-words-censor v1.1.0

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

Vulgar words censor

Just a simple package for censoring vulgar words

{
  "bad": "--CENSORED--",
  "good": "Let's go to library"
}

Installation:

npm install vulgar-words-censor --save

Usage:

The javascript discipline used in this package is ES6 where the package.json is set to "type": "module"

import { censor } from "vulgar-words-censor";

let bad_dummytext = "This mother fucker is teribble !";
let good_dummytext = "Let's go to library";

console.log({
  bad: censor(bad_dummytext),
  good: censor(good_dummytext),
});

/**
 * output
 * {
 *      bad: '--CENSORED--',
 *      good: "Let's go to library"
 * }
 */