@qiwi/masker-secret-value
v2.0.1
Published
Masker plugin to hide sensitive values by pattern
Downloads
905
Readme
@qiwi/masker-secret-value
Masker plugin to conceal sensitive values by pattern match.
Install
yarn add @qiwi/masker-secret-value
Usage
import {masker} from '@qiwi/masker'
import {pipe} from '@qiwi/masker-secret-value'
masker('fooo bar baz foobar qux q', {
pipeline: [['secret-value', {pattern: /\w{4,}/g}]]
})
// **** bar baz ****** qux q