You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you have experience using `ReactJS`, `Redux`, `React Router` and `Webpack` then by going through the folder/files will give you the idea on how to accomplish this
280
281
281
282
283
+
284
+
## Adding a Linter: [ESLint](https://eslint.org/)
285
+
### Local installation
286
+
```
287
+
$ npm i eslint --save-dev
288
+
```
289
+
290
+
### Configuration file setup
291
+
```
292
+
$ ./node_modules/.bin/eslint --init
293
+
```
294
+
295
+
### ESLint prerequisites
296
+
*[babel-eslint](https://github.com/babel/babel-eslint) - Lint all valid Babel code
297
+
*[eslint-loader](https://github.com/MoOx/eslint-loader) - Linting JS files using eslint with webpack
298
+
*[eslint-plugin-react](https://github.com/yannickcr/eslint-plugin-react) - React specific linting rules for ESLint
299
+
300
+
### Additional rules to get rid of React warnings
301
+
```
302
+
rules: {
303
+
...
304
+
"react/jsx-uses-react": [2],
305
+
"react/jsx-uses-vars": [2],
306
+
...
307
+
}
308
+
```
309
+
310
+
### Additional environment to get rid of other warnings
311
+
```
312
+
env: {
313
+
...
314
+
// Webpack module.hot
315
+
"commonjs": true,
316
+
// require()
317
+
"amd": true
318
+
...
319
+
}
320
+
```
321
+
322
+
323
+
282
324
## References
283
325
[For Java Web installation](https://devcenter.heroku.com/articles/create-a-java-web-application-using-embedded-tomcat)
[For configuring `eslint-loader` with Webpack](https://www.learnhowtoprogram.com/react/react-fundamentals/building-an-environment-automatic-linting-with-webpack)
0 commit comments