Skip to content

Commit

Permalink
🔧Eslint, prettier and tsconfig setup
Browse files Browse the repository at this point in the history
  • Loading branch information
Max authored and Max committed Apr 25, 2020
1 parent d7cabd4 commit 5ad4b10
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 24 deletions.
File renamed without changes.
21 changes: 7 additions & 14 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,26 +3,19 @@
"noEmit": true,
"allowJs": true,
"esModuleInterop": true,
"baseUrl": ".",
"baseUrl": "web/src",
"target": "es5",
"lib": [
"es2015",
"es2017",
"DOM"
],
"lib": ["es2019", "DOM"],
"skipLibCheck": true,
"strict": false,
"forceConsistentCasingInFileNames": true,
"module": "esnext",
"moduleResolution": "node",
"resolveJsonModule": true,
"isolatedModules": true,
"jsx": "preserve"
"jsx": "preserve",
"sourceMap": true
},
"include": [
"."
],
"exclude": [
"node_modules"
]
}
"include": ["."],
"exclude": ["node_modules"]
}
33 changes: 23 additions & 10 deletions web/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,26 @@
module.exports = {
"extends": ["airbnb-typescript", "prettier"],
"plugins": ["prettier"],
"parserOptions": {
"project": "./tsconfig.json"
extends: [
'airbnb-typescript',
'prettier',
'prettier/react',
'prettier/@typescript-eslint',
],
plugins: ['prettier', '@typescript-eslint'],
parser: '@typescript-eslint/parser',
parserOptions: {
project: './web/tsconfig.json',
},
settings: {
react: {
version: 'detect',
},
},
rules: {
'import/prefer-default-export': 'off',
'react/react-in-jsx-scope': 'off',
'react/jsx-props-no-spreading': 'off',
'@typescript-eslint/no-dupe-class-members': 'off',
'@typescript-eslint/no-implied-eval': 'off',
'@typescript-eslint/no-throw-literal': 'off',
},
"rules": {
"prettier/prettier": ["error"],
"import/prefer-default-export": "off",
"react/react-in-jsx-scope": "off",
"react/jsx-props-no-spreading": "off"
}
};

0 comments on commit 5ad4b10

Please sign in to comment.