forked from wilsoniovlabs/relaying-services-sdk-dapp
-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy path.eslintrc.cjs
39 lines (38 loc) · 876 Bytes
/
.eslintrc.cjs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
// a11y rules are disabled because of out-of-scope for this sample app
const a11yOff = Object.keys(require('eslint-plugin-jsx-a11y').rules).reduce(
(acc, rule) => {
acc[`jsx-a11y/${rule}`] = 'off';
return acc;
},
{}
);
module.exports = {
env: {
browser: true,
es2021: true,
},
extends: [
'plugin:react/recommended',
'airbnb',
'airbnb-typescript',
'prettier',
],
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaFeatures: {
jsx: true,
},
ecmaVersion: 12,
sourceType: 'module',
project: './tsconfig.json',
},
plugins: ['react', '@typescript-eslint'],
rules: {
'react/react-in-jsx-scope': 'off',
'react/require-default-props': 'off',
...a11yOff,
'no-alert': 'off',
// TODO: we need to replace the console.log calls with a log library
'no-console': 'off',
},
};