1.1.11 • Published 4 years ago

@h4iuiuc/eslint-plugin v1.1.11

Weekly downloads
-
License
MIT
Repository
github
Last release
4 years ago

DEPRECATION NOTICE: This package has been moved to @hack4impact-uiuc/eslint-plugin and will not be publishing further versions under the h4iuiuc scope

eslint-plugin npm package build

An ESLint plugin intended for use with Hack4Impact UIUC projects.

Installation

You'll first need to install ESLint:

npm i eslint --save-dev

Next, install @h4iuiuc/eslint-plugin:

npm install @h4iuiuc/eslint-plugin --save-dev

Usage

To enable @h4iuiuc/eslint-plugin, you'll need to create a .eslintrc.json file for ESLint configuration.

This plugin abstracts away configuration from the user, extending configs from eslint-plugin-import, eslint-plugin-jsx-a11y, eslint-plugin-react, and eslint-plugin-react-hooks through the recommended config (inspired by eslint-config-react-app).

For a JavaScript-only app all you'll need to have in your .eslintrc.json file is the following:

{
  "plugins": ["@h4iuiuc"],
  "extends": ["plugin:@h4iuiuc/recommended"]
}

If your app uses TypeScript at all, you'll want to use @typescript-eslint/eslint-plugin by extending the typescript config as follows:

{
  "plugins": ["@h4iuiuc"],
  "extends": ["plugin:@h4iuiuc/recommended", "plugin:@h4iuiuc/typescript"]
}

If you need to modify or disable specific rules, you can do so in the rules section of your .eslintrc.json file. For example, if you wish to disable no-anonymous-parameterless-props, add the following to your .eslintrc.json file:

{
  "rules": {
    "@h4iuiuc/no-anonymous-parameterless-props": "off"
  }
}

Note that disabling rules from plugins requires prefixing them with their corresponding scope and/or plugin name.

Fixes

Some rules (see table below) are fixable using the --fix ESLint option.

Supported Rules

Rules

RuleDefaultFixable
no-access-state-after-set:triangular_flag_on_post::x:
no-null-ternary:triangular_flag_on_post::heavy_check_mark:
no-anonymous-parameterless-props:triangular_flag_on_post::heavy_check_mark:

Key

SymbolMeaning
:triangular_flag_on_post:Error
:warning:Warning
:heavy_multiplication_x:Off
:heavy_check_mark:Fixable and autofix-enabled
:x:Not fixable
1.1.11

4 years ago

1.1.10

4 years ago

1.1.9

4 years ago

1.1.8

4 years ago

1.1.7

4 years ago

1.1.6

4 years ago

1.1.5

4 years ago

1.1.4

4 years ago

1.1.1

4 years ago

1.1.0

4 years ago

1.1.3

4 years ago

1.1.2

4 years ago

1.0.12

4 years ago

1.0.11

4 years ago

1.0.10

4 years ago

1.0.9

5 years ago

1.0.8

5 years ago

1.0.7

5 years ago

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago

1.0.0-preview.3

5 years ago

1.0.0-preview.2

5 years ago

1.0.0-preview.1

5 years ago