Skip to content

Commit a9fc4ad

Browse files
committed
Merge pull request #462 from thaggie/readme-info
Added a note about the recommended configuration at the bottom of the configuration section.
2 parents 1e487fc + bcd603c commit a9fc4ad

File tree

1 file changed

+15
-2
lines changed

1 file changed

+15
-2
lines changed

README.md

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,19 @@ With ESLint 2.x.x:
6969

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

72+
At a minimum you need to include the rule [jsx-uses-vars](docs/rules/jsx-uses-vars.md) as without this
73+
any imports of JSX components will fail falsely claiming they're defined but not used.
74+
75+
```json
76+
{
77+
"rules": {
78+
"react/jsx-uses-vars": 2
79+
}
80+
}
81+
```
82+
83+
The plugin has a [recommended configuration](#user-content-recommended-configuration) that enforces React good practices.
84+
7285
# List of supported rules
7386

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

120133
# Recommended configuration
121134

122-
This plugin export a `recommended` configuration that enforce React good practices.
135+
This plugin exports a `recommended` configuration that enforce React good practices.
123136

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

@@ -128,7 +141,7 @@ To enable this configuration use the `extends` property in your `.eslintrc` conf
128141
"plugins": [
129142
"react"
130143
],
131-
"extends": "plugin:react/recommended"
144+
"extends": ["eslint:recommended", "plugin:react/recommended"]
132145
}
133146
```
134147

0 commit comments

Comments
 (0)