Skip to content
An Example for publishing npm module. Learnt from here - https://egghead.io/courses/publish-javascript-packages-on-npm
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src
.npmignore
README.md
package.json

README.md

Example

$ npm install sensitive-words --save
const {sensitiveWords} = required('sensitive-words')
//ES2015 modules
import {sensitiveWords} from 'sensitive-words'

const {sensitiveWords} = require('sensitive-words');

const filtered = sensitiveWords(
  'The new apple mac book pro has touch bar',
  ['pro', 'bar']
)

console.log(filtered);
//The new apple mac book **** has touch ****
You can’t perform that action at this time.