Skip to content

Commit

Permalink
chore: move to eslint flat config
Browse files Browse the repository at this point in the history
Moves to using an ESLint flat config.
  • Loading branch information
43081j committed Feb 3, 2025
1 parent f446294 commit 19f6b99
Show file tree
Hide file tree
Showing 6 changed files with 87 additions and 35 deletions.
1 change: 0 additions & 1 deletion .eslintignore

This file was deleted.

16 changes: 0 additions & 16 deletions .eslintrc.json

This file was deleted.

30 changes: 30 additions & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
import eslintjs from "@eslint/js";
import globals from 'globals';

const {configs: eslintConfigs} = eslintjs;

export default [
{
ignores: [
'coverage/'
],
},
eslintConfigs["recommended"],
{
files: ['test/**/*.js'],
languageOptions: {
globals: {
...globals.browser,
}
}
},
{
files: ['test/**/*.js'],
languageOptions: {
globals: {
...globals.mocha,
...globals.node,
}
}
}
];
66 changes: 55 additions & 11 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,11 @@
"chai": ">= 2.1.2 < 6"
},
"devDependencies": {
"@eslint/js": "^9.19.0",
"c8": "^10.0.0",
"chai": "^5.1.0",
"eslint": "^8.57.0",
"globals": "^15.14.0",
"mocha": "^10.4.0",
"prettier": "^3.2.5"
}
Expand Down
7 changes: 0 additions & 7 deletions test/.eslintrc.json

This file was deleted.

0 comments on commit 19f6b99

Please sign in to comment.