Skip to content

Commit e57b07f

Browse files
committed
chore: add plugin and first min config
1 parent 1688612 commit e57b07f

File tree

4 files changed

+70
-9
lines changed

4 files changed

+70
-9
lines changed

.eslintignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
.next
22
node_modules
3-
test
43
lib
54
demos
65
packages/runtime/src/templates/edge

.eslintrc.js

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,5 +59,18 @@ module.exports = {
5959
'promise/catch-or-return': 0,
6060
},
6161
},
62+
{
63+
files: ['test/**'],
64+
plugins: ['jest'],
65+
extends: ['plugin:jest/recommended'],
66+
rules: {
67+
// Disable global rules
68+
'max-nested-callbacks': 0,
69+
'@typescript-eslint/no-empty-function': 0,
70+
'max-lines-per-function': 0,
71+
// esling-plugin-jest specific rules
72+
'jest/consistent-test-it': ['error', { fn: 'it', withinDescribe: 'it' }],
73+
}
74+
}
6275
],
6376
}

package-lock.json

Lines changed: 53 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@
2929
"test:update": "run-s build build:demo test:jest:update"
3030
},
3131
"config": {
32-
"eslint": "--cache --format=codeframe --max-warnings=0 \"{packages,src,scripts,tests,.github}/**/*.{ts,js,md,html}\" \"*.{ts,js,md,html}\" \".*.{ts,js,md,html}\"",
33-
"prettier": "--loglevel=warn \"{packages,src,scripts,tests,.github}/**/*.{ts,js,md,yml,json,html}\" \"*.{ts,js,yml,json,html}\" \".*.{ts,js,yml,json,html}\" \"!package-lock.json\""
32+
"eslint": "--cache --format=codeframe --max-warnings=0 \"{packages,test,.github}/**/*.{ts,js,md,html}\" \"*.{ts,js,md,html}\" \".*.{ts,js,md,html}\"",
33+
"prettier": "--loglevel=warn \"{packages,test,.github}/**/*.{ts,js,md,yml,json,html}\" \"*.{ts,js,yml,json,html}\" \".*.{ts,js,yml,json,html}\" \"!package-lock.json\""
3434
},
3535
"repository": {
3636
"type": "git",
@@ -67,6 +67,7 @@
6767
"cypress": "^12.10.0",
6868
"escape-string-regexp": "^2.0.0",
6969
"eslint-config-next": "^12.0.0",
70+
"eslint-plugin-jest": "^27.2.1",
7071
"eslint-plugin-promise": "^6.0.0",
7172
"eslint-plugin-unicorn": "^43.0.2",
7273
"execa": "^5.1.1",
@@ -78,6 +79,7 @@
7879
"mock-fs": "^5.2.0",
7980
"netlify-plugin-cypress": "^2.2.1",
8081
"npm-run-all": "^4.1.5",
82+
"pathe": "^1.1.0",
8183
"playwright-chromium": "1.28.1",
8284
"prettier": "^2.1.2",
8385
"react": "^18.2.0",

0 commit comments

Comments
 (0)