Port to typescript

This commit is contained in:
she11sh0cked
2020-12-24 16:50:50 +01:00
parent 59c69a4f7f
commit efbb2a8524
16 changed files with 762 additions and 739 deletions

View File

@@ -1,33 +1,17 @@
module.exports = {
env: {
browser: true,
es2021: true,
},
extends: [
'plugin:react/recommended',
'airbnb',
],
extends: ['airbnb-typescript'],
plugins: ['@typescript-eslint'],
parserOptions: {
ecmaFeatures: {
jsx: true,
},
ecmaVersion: 12,
sourceType: 'module',
project: './tsconfig.json',
},
plugins: [
'react',
],
rules: {
// Indent with 4 spaces
indent: ['error', 4],
'@typescript-eslint/indent': ['error', 4],
// Indent JSX with 4 spaces
'react/jsx-indent': ['error', 4],
// Indent props with 4 spaces
'react/jsx-indent-props': ['error', 4],
// allow JSX in both js and jsx files
'react/jsx-filename-extension': [1, { extensions: ['.js', '.jsx'] }],
},
};