Gojob ESLint
Feel free to extend our opinionated ESLint configurations.
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:
{
"extends": [
"@gojob/eslint-config/typescript"
],
}
Assuming you already installed typescript
...
yarn add --dev eslint @gojob/eslint-config prettier
npm install --save-dev eslint @gojob/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"
}