1.0.0 • Published 5 years ago
dirty-words v1.0.0
Example
Install
$ npm install dirty-words
Create
// dont forget to add .default
const { dirtyWords } = require("dirty-words").default;
// ES2015+
import {dirtyWords} from "dirty-words"
Usage
replaces the chosen words in a string with five asterisks
const dirtyWords = require('dirty-words').default;
const filtered = dirtyWords('apple is selling a metal monitor stand for $999.99? that is really crazy!', ['metal', 'really']);
// apple is selling a ***** monitor for $999.99? that is ***** crazy!
Thanks!
1.0.0
5 years ago