ESLint Module #48 Flashcards
1
Q
ESLint what’s it do again?
A
Calls out errors in your code, prevents infinite loops, check for duplicative switch statements etc.
2
Q
How do I install it?
A
npm install -g eslint
# create a `.eslintrc` configuration file eslint --init
3
Q
How do I run it on my js files?
A
# run ESLint against any file with eslint yourfile.js
4
Q
What if you want to share your code with a team whoe prefers you use semi-colons and uses the Airbnb Style guide?
A
npm install –save-dev eslint-config-airbnb