Skip to content

Commit 1030daf

Browse files
refactor: use flat config for eslint (#201)
* refactor: use flat config for eslint * chore: update * Apply suggestions from code review Co-authored-by: Milos Djermanovic <[email protected]> * Update eslint.config.js Co-authored-by: Milos Djermanovic <[email protected]> --------- Co-authored-by: Milos Djermanovic <[email protected]>
1 parent 256e089 commit 1030daf

File tree

14 files changed

+1337
-566
lines changed

14 files changed

+1337
-566
lines changed

.eslintignore

Lines changed: 0 additions & 1 deletion
This file was deleted.

.eslintrc.js

Lines changed: 0 additions & 32 deletions
This file was deleted.

eslint.config.js

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
"use strict";
2+
3+
const eslintConfigESLint = require("eslint-config-eslint/cjs");
4+
const globals = require("globals");
5+
6+
module.exports = [
7+
...eslintConfigESLint,
8+
{
9+
ignores: ["coverage/"]
10+
},
11+
{
12+
rules: {
13+
camelcase: ["error", { properties: "never" }],
14+
15+
// Remove after https://github.com/eslint/eslint/pull/17900 is included in new release
16+
"jsdoc/no-multi-asterisks": ["error", { allowWhitespace: true }]
17+
}
18+
},
19+
{
20+
files: ["eslint.config.js", "tests/**/*.js"],
21+
languageOptions: {
22+
globals: {
23+
...globals.jest
24+
}
25+
},
26+
rules: {
27+
"n/no-unpublished-require": "off",
28+
"n/no-extraneous-require": [
29+
"error",
30+
{
31+
allowModules: [
32+
"@octokit/rest"
33+
]
34+
}
35+
]
36+
}
37+
}
38+
];

0 commit comments

Comments
 (0)