-
Notifications
You must be signed in to change notification settings - Fork 5
/
.eslintrc.cjs
45 lines (45 loc) · 1.15 KB
/
.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
40
41
42
43
44
45
/**
* @type {import('@types/eslint').Linter.BaseConfig}
*/
module.exports = {
extends: [
"@remix-run/eslint-config",
"@remix-run/eslint-config/node",
"@remix-run/eslint-config/jest-testing-library",
"prettier",
],
// we're using vitest which has a very similar API to jest
// (so the linting plugins work nicely), but it we have to explicitly
// set the jest version.
settings: {
jest: {
version: 27,
},
},
ignorePatterns: ["build/*", "public/build/*", "api/*", "coverage/*", "cypress/*"],
rules: {
"@typescript-eslint/consistent-type-imports": 0,
"import/order": [
"error",
{
alphabetize: { order: "asc", caseInsensitive: true },
groups: ["builtin", "external", "index", "parent", ["internal", "sibling"]],
},
],
"react/jsx-sort-props": [
"error",
{
callbacksLast: true,
shorthandFirst: true,
ignoreCase: false,
reservedFirst: true,
},
],
"testing-library/no-render-in-setup": [
"error",
{ allowTestingFrameworkSetupHook: "beforeEach" },
],
eqeqeq: "warn",
"no-unneeded-ternary": "error",
},
}