Skip to content

Latest commit

 

History

History
44 lines (33 loc) · 1.23 KB

README.md

File metadata and controls

44 lines (33 loc) · 1.23 KB

Yet another opinionated ESLint configuration

Feel free to extend it.
Initially made at Gojob, see @gojob/eslint-config.

TypeScript

With the deprecation of TSLint (we'll miss you, buddy), we decided to progressively switch all our linting processes to ESLint.

Installation

You can extend our default configuration, in your own ESLint configuration (e.g. .eslintrc):

{
  "extends": [
    "@vinceops/eslint-config/typescript" // or typescript-react
  ],
}

Assuming you already installed typescript...

yarn add --dev eslint @vinceops/eslint-config prettier
# or
npm install --save-dev eslint @vinceops/eslint-config prettier

Integration with VSCode

At the present time, the ESLint plugin for VSCode has difficulties parsing/fixing TypeScript. Adding the following configuration to VSCode settings (.vscode/settings.json in your project) solves the problem:

{
  "eslint.validate": [
    "javascript",
    "javascriptreact",
    { "language": "typescript", "autoFix": true },
    "typescriptreact"
  ],
  "typescript.tsdk": "node_modules/typescript/lib"
}