A Korean profanity filter library for Node.js and browser, v1.0.4 (current stable). Provides a Filter class with customizable placeholder, regex, and blacklist management (add/remove words). Supports ES6+ import syntax. Built as a Korean adaptation of the bad-words npm package. Lightweight, no dependencies, TypeScript definitions not shipped. Slow release cadence (last update 2022). Differentiator: specifically targets Korean profanity with a built-in blacklist of Korean curse words, unlike generic profanity filters.
npm install badwords-koNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Creates a Filter instance, checks for profanity, cleans text with default/regex/placeholder, adds and removes custom blacklist words.
Consider using 'bad-words-next' or build your own filter for better maintainability.
Use 'replaceRegex' option to control replacement regex, not 'regex'.
Use filter.addWords(...list) instead of filter.addWords(list).
Use ES modules or set project to type: module. Alternatively, use dynamic import() in CommonJS.
Use const Filter = require('badwords-ko').default;Add 'type': 'module' to package.json or use .mjs extension.
Ensure you don't set emptyList: true unless you intend to add words later. Use new Filter() without options.
No dependency data recorded yet.