Skip to content

Commit 38456f3

Browse files
authored
Update setup.md
Resolutions for merge
1 parent e0419c0 commit 38456f3

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

docs/setup.md

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,29 @@
11
In order to use the react eslint plugin do the following...
22

33
1. At the root of your project type <code>npm install eslint-plugin-react --save-dev</code>
4-
2. Check your package.json 'devDependencies' for the following entries (version numbers may vary)...
4+
2. Check your package.json 'devDependencies' for the following entries (version numbers may vary, but it's important that **the eslint version matches the peerDependency version in eslint-plugin-react**)...
55
<pre>
66
"devDependencies": {
77
"eslint": "^3.19.0",
88
"eslint-plugin-react": "^6.10.3"
99
}
1010
</pre>
11-
3. In your eslint configuration file (.eslint.rc / package.json etc.) add the following under 'esLintConfig'...
11+
3. If configuring using package.json add the following under 'esLintConfig'...
1212
<pre>
1313
"eslintConfig": {
1414
"plugins": [
1515
"react"
1616
]
1717
}
1818
</pre>
19+
Else, in your eslint configuration file (.eslintrc) add the following...
20+
<pre>
21+
{
22+
"plugins": [
23+
"react"
24+
]
25+
}
26+
</pre>
1927
4. Configure the rules you want to use according to the [rules docs](/docs/rules). Here's a sample of some of mine...
2028
<pre>
2129
"eslintConfig": {

0 commit comments

Comments
 (0)