1.0.3 • Published 2 years ago

@stevencho/eslint-config-fitpet v1.0.3

Weekly downloads
-
License
ISC
Repository
-
Last release
2 years ago

Install

  1. CRA
npx create-react-app my-app
  1. Intall package
npm i -D @stevencho/eslint-config-fitpet
  1. Create .eslintrc
{
  "extends": ["@stevencho/eslint-config-fitpet"]
}
  1. Add lint script to package.json
"scripts": {
  "lint": "eslint .",
  "lint:fix": "eslint . --fix"
},

Override prettier settings

Add rules in .eslintrc to override @devstefancho/eslint-config-react rules

{
  "extends": ["@stevencho/eslint-config-fitpet"],
  "rules": {
    "no-console": 2,
    "prettier/prettier": [
      "error",
      {
        "trailingComma": "es5",
        "singleQuote": true,
        "printWidth": 120,
        "tabWidth": 2,
      }
    ]
  }
}

Webstorm

on Mac

  • Preference(cmd + ,) > Check 'Automatic ESLint configuration' and 'Run eslint --fix on save'

Ref

Youtube

Docs

Github

1.0.3

2 years ago

1.0.3-beta.0

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago