the-big-username-blacklist
This is a opinionated blacklist of words that you might not like to see used as usernames in your service.
Last updated 2 years ago by marteinn .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install the-big-username-blacklist 
SYNC missed versions from official npm registry.

Build Status npm version

The-Big-Username-Blacklist-JS

This library lets you validate usernames against a blacklist. The blacklist data is based on the data from The-Big-Username-Blacklist and contains privilege, programming terms, section names, financial terms and actions.

You can try the blacklist using the tool Username checker.

How it works

the-big-username-blacklist exposes a function named validate, you can use that function to see if a word is occuring in the blacklist.

Usage

Validating a username is easy, if the word is in the blacklist, return False (validation failed), otherwise True. Example:

>>>> var blacklist = require("the-big-username-blacklist");
>>>> blacklist.validate("martin");
true
>>>> blacklist.validate("root");
false

The same would be written like this in ES6.

>>>> import blacklist from "the-big-username-blacklist";
>>>> blacklist.validate("martin");
true
>>>> blacklist.validate("root");
false

Access the blacklist

If you only want to retrive the blacklist data, you can find it in the list property.

>>>> var blacklist = require("the-big-username-blacklist");
>>>> console.log(blacklist.list);
[ '400',
  '401',
  '403'...

The same would be written like this in ES6.

>>>> import {list} from "the-big-username-blacklist";
>>>> console.log(list);
[ '400',
  '401',
  '403'...

Installation

This package is available through npm

$ npm install the-big-username-blacklist

We also include a minified version that you can put on your cdn:

Tests

It's simple, just run:

npm run test

Contributing

Want to contribute? Awesome. Just send a pull request.

All code are in es6 format and can be found in the src directory, to compile back to es5 type: npm run build

License

The-Big-Username-Blacklist is released under the MIT License.

Current Tags

  • 1.5.2                                ...           latest (2 years ago)

13 Versions

  • 1.5.2                                ...           2 years ago
  • 1.5.1                                ...           4 years ago
  • 1.5.0                                ...           4 years ago
  • 1.4.0                                ...           4 years ago
  • 1.3.4                                ...           4 years ago
  • 1.3.3                                ...           4 years ago
  • 1.3.2                                ...           4 years ago
  • 1.3.1                                ...           5 years ago
  • 1.3.0                                ...           5 years ago
  • 1.2.0                                ...           5 years ago
  • 1.1.0                                ...           5 years ago
  • 1.0.1                                ...           5 years ago
  • 1.0.0                                ...           5 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 7
Last Day 0
Last Week 2
Last Month 2
Dependencies (0)
None
Dev Dependencies (7)

Copyright 2014 - 2016 © taobao.org |