1.1.7 • Published 2 years ago
eslint-config-pecode v1.1.7
This is ESlint configuration for Pecode Software
1) First of all, be sure you are installed ESlint globally npm install -g eslint
2) Install ESlint plugin for VScode:
- you could use this link https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint
- or install it through your VSCode
3) Open your project folder and call the terminal, then type next command and press
Enter
npm i eslint eslint-plugin-chai-friendly eslint-plugin-cypress eslint-plugin-import eslint-config-pecode
4) After all, packages will be installed, create.eslintrc.json
file at the root of your project and copy-paste this code inside this file
{
"extends": "eslint-config-pecode"
}
5) Configure your ESlint in VSCode so it will fix all errors on save
:
- Go to File > Preferences > Settings > Workplace and try to find:
Editor: Code Actions On Save
- click on it Then modify
Settings.json
:"In settings.json paste the following code:
{
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
},
"eslint.validate": ["javascript"]
}
Happy coding 🎉