Skip to content

Added a note about the recommended configuration at the bottom of the configuration section. #462

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 27, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 15 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,19 @@ With ESLint 2.x.x:

Finally, enable all of the rules that you would like to use.

At a minimum you need to include the rule [jsx-uses-vars](docs/rules/jsx-uses-vars.md) as without this
any imports of JSX components will fail falsely claiming they're defined but not used.

```json
{
"rules": {
"react/jsx-uses-vars": 2
}
}
```

The plugin has a [recommended configuration](#user-content-recommended-configuration) that enforces React good practices.

# List of supported rules

* [display-name](docs/rules/display-name.md): Prevent missing `displayName` in a React component definition
Expand Down Expand Up @@ -119,7 +132,7 @@ If you're searching for React Native specific linting rules, check out [eslint-p

# Recommended configuration

This plugin export a `recommended` configuration that enforce React good practices.
This plugin exports a `recommended` configuration that enforce React good practices.

To enable this configuration use the `extends` property in your `.eslintrc` config file:

Expand All @@ -128,7 +141,7 @@ To enable this configuration use the `extends` property in your `.eslintrc` conf
"plugins": [
"react"
],
"extends": "plugin:react/recommended"
"extends": ["eslint:recommended", "plugin:react/recommended"]
}
```

Expand Down