eslint-plugin-no-empty-disable
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

eslint-plugin-no-eslint-disable

Disallow eslint-disable comments without at least one rule.

RULE ID

no-empty-eslint-disable/no-empty-eslint-disable

USAGE

// .eslintrc
{
  ...
  "plugins": ["no-empty-eslint-disable"]
  ...
  "rules": {
    ...
    "no-empty-eslint-disable/no-empty-eslint-disable": "error"
    ...
  }
}

EXAMPLES

These will error

  • const x = 1; // eslint-disable-line
  • // eslint-disable-next-line
  • /* eslint-disable */

These are okay

  • console.log('') // eslint-disable-line no-console
  • // eslint-disable-next-line eqeqeq
  • /* eslint-disable no-empty */

TODO

  • Uses tslint which has now been depecated. Migrate to eslint

Heavily inspired by [https://github.com/unlight/eslint-plugin-no-eslint-disable]

Package Sidebar

Install

npm i eslint-plugin-no-empty-disable

Weekly Downloads

0

Version

1.0.0

License

MIT

Unpacked Size

12.6 kB

Total Files

12

Last publish

Collaborators

  • ejp