This package conceals the email part in a string with example.org, this can be used to conceal the emails in sql dumps.
Inspired by: https://github.com/spatie/email-concealer
It removes the domain and append the local part with example.org. Concealer can idenfity if there are more than one same local part than it will increment the count and append it.
npm install email-concealer --save
let string = 'hi alex@gmail.com';
const concealer = new Concealer();
concealer.conceal(string);
// hi alex@example.org
string = 'hi alex@gmail.com and alex@yahoo.in';
concealer.conceal(string);
// hi alex@example.org and alex-1@example.org
You can use the email-concealer command line interface (cli)
Commands:
email-concealer --help
email-concealer --version
email-concealer conceal --file [filepath] --domain [domain]
Example:
email-concealer conceal --file ./users.sql --domain example.org
npm test
Please see CHANGELOG for more information what has changed recently.
Please see CONTRIBUTING and CODE OF CONDUCT for details.
The MIT License (MIT). Please see License File for more information.