Skip to content

vas-dev/eslint-config

Folders and files

NameName
Last commit message
Last commit date

Latest commit

49e3b2c Β· Dec 2, 2019

History

6 Commits
Oct 8, 2019
Oct 8, 2019
Oct 8, 2019
Oct 8, 2019
Oct 8, 2019
Oct 8, 2019
Dec 2, 2019
Oct 8, 2019
Dec 2, 2019
Dec 2, 2019

Repository files navigation

@vas-dev/eslint-config

eslint config for VAS projects based on react-app and standard

Usage

If using create-react-app:

  1. Add as devDependency
    yarn add --dev @vas-dev/eslint-config
  2. Add to package.json
    "eslintConfig": {
      "extends": "@vas-dev"
    },

If not using create-react-app:

  1. Add dependencies
    yarn add --dev eslint babel-eslint eslint-config-react-app eslint-plugin-flowtype eslint-plugin-import eslint-plugin-jsx-a11y eslint-plugin-react eslint-plugin-react-hooks
  2. Add to package.json
    "eslintConfig": {
      "extends": "@vas-dev"
    },

Rule Overrides

"no-console": "error",
"object-curly-spacing": ["error", "always"],
"react-hooks/rules-of-hooks": "error",
"prefer-promise-reject-errors": "off",
"jest/consistent-test-it": ["error", { "fn": "it" }],
"jest/no-empty-title": "error",
"jest/no-truthy-falsy": "error",
"jest/no-test-return-statement": "error",
"jest/no-test-callback": "error",
"jest/prefer-to-be-null": "error",
"jest/prefer-to-be-undefined": "error",
"jest/prefer-to-have-length": "error",
"jest/prefer-to-contain": "error",
"jest-formatting/padding-before-test-blocks": "error",
"jest-formatting/padding-before-describe-blocks": "error"