1.1.7 • Published 3 years ago

eslint-plugin-diversity-inclusion v1.1.7

Weekly downloads
-
License
ISC
Repository
github
Last release
3 years ago

eslint-plugin-diversity-inclusion

eslint plugin to encourage the use of inclusive code

Table of contents

Getting started

You'll first need to install ESLint:

$ npm i eslint --save-dev

Next, install eslint-plugin-diversity-inclusion:

$ npm install eslint-plugin-diversity-inclusion --save-dev

Note: If you installed ESLint globally (using the -g flag) then you must also install eslint-plugin-diversity-inclusion globally.

Usage

Add diversity-inclusion to the plugins section of your .eslintrc configuration file. You can omit the eslint-plugin- prefix:

{
  "plugins": ["diversity-inclusion"]
}

Then configure the rules you want to use under the rules section. You can choose from all supported rules, but it is encouraged to use all rules. Value 0 will turn the rules off, 1 will return a warning, 2 an error.

{
  "rules": {
    "diversity-inclusion/all": 1
  }
}

Example of warning in the console:

 warning  "master" could be seen as insensitive, please use (a variant of) "primary,main,leader" instead 

Supported Rules

  • all
  • racism
  • disabilities

Contributions Welcome

While this plugin attemts to call attention to as many offensive terms as possible, the work of inclusivity is never complete. Please help to expand the categories and offensive words list so that we can all benefit from our collective lived experiences.

1.1.1

4 years ago

1.1.0

4 years ago

1.1.7

3 years ago

1.1.6

3 years ago

1.1.5

3 years ago

1.1.4

3 years ago

1.1.3

4 years ago

1.1.2

4 years ago

1.0.2

4 years ago