-
Notifications
You must be signed in to change notification settings - Fork 23
/
.eslintrc.js
37 lines (37 loc) · 870 Bytes
/
.eslintrc.js
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
module.exports = {
root: true,
parser: "babel-eslint", // Specifies the ESLint parser
extends: [
"plugin:jsx-a11y/recommended",
"airbnb",
"plugin:prettier/recommended", // Enables eslint-plugin-prettier and displays prettier errors as ESLint errors. Make sure this is always the last configuration in the extends array
"prettier/react",
"plugin:import/errors",
"plugin:import/warnings",
"plugin:react/recommended",
],
rules: {
"no-unused-vars": [
"error",
{ varsIgnorePattern: "^h$" }, // allow stuffs (prevState => ({})) and import h from 'preact'
],
},
env: {
browser: true,
es6: true,
},
settings: {
"import/resolver": {
node: {
extensions: [".js"],
},
},
react: {
pragma: "h",
},
},
globals: {
NODE_ENV: true,
API_BASE_URL: true,
},
};