eslint-plugin-superstition

0.3.1 • Public • Published

eslint-plugin-superstition

ESLint superstition rules (forbid using numbers 13, 666 and etc.)

Install

$ npm install --save-dev eslint eslint-plugin-superstition

Usage

Configure it in package.json.

{
  "name": "my-awesome-project",
  "eslintConfig": {
    "env": {
      "es6": true
    },
    "plugins": [
      "superstition"
    ],
    "rules": {
      "superstition/must-have-8": "error",
      "superstition/no-number-13": "error",
      "superstition/no-number-39": "error",
      "superstition/no-number-4": "error",
      "superstition/no-number-666": "error",
      "no-var": "error"
    }
  }
}

Rules

  • must-have-8 - Must have to use of the number 8. It brings good luck.
  • no-number-13 - Forbid the use of number 13. It is a bad omen.
  • no-number-39 - Forbid the use of number 39. It is a bad omen.
  • no-number-4 - Forbid the use of number 4. It is a bad omen.
  • no-number-666 - Forbid the use of number 666. It is a bad omen.

Recommended configuration

This plugin exports a recommended configuration that enforces good practices.

To enable this configuration, use the extends property in your package.json.

{
  "name": "my-awesome-project",
  "eslintConfig": {
    "plugins": [
      "superstition"
    ],
    "extends": "plugin:superstition/recommended"
  }
}

See ESLint documentation for more information about extending configuration files.

Notes

Based on eslint-plugin-fp


MIT © Pavel Gurov

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.3.1
    1
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.3.1
    1
  • 0.3.0
    0
  • 0.2.0
    0
  • 0.1.0
    0

Package Sidebar

Install

npm i eslint-plugin-superstition

Weekly Downloads

1

Version

0.3.1

License

MIT

Unpacked Size

8.29 kB

Total Files

9

Last publish

Collaborators

  • gurov