Skip to content

Latest commit

 

History

History
25 lines (17 loc) · 730 Bytes

README.md

File metadata and controls

25 lines (17 loc) · 730 Bytes

NPM package publish test

Make abusive comments cute by replacing specified words with a random emoji 😸

(Pull Requests very welcome, let's have some fun)

Installation

$ npm install happy-thoughts --dev

Usage

const { happyThoughts } = require( "happy-thoughts" )

// Es2015 module import
// import happyThoughts from 'happy-thoughts'

const singleWord = happyThoughts( `Kal-El's a bit of bore -Batman`, [ "bore" ] )
const multipleWords = happyThoughts( `Why is Superman wearing his mother's tights lol -Batman`, [ "mother", "tights" ] )

console.log( singleWord )    // Kal-El's a bit of 🙀 -Batman
console.log( multipleWords ) // Why is Superman wearing his 🙌's 🙀 lol -Batman