Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(eslint): switch to new eslint config format #183

Merged
merged 1 commit into from
May 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 0 additions & 11 deletions .eslintrc.json

This file was deleted.

23 changes: 23 additions & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
const js = require("@eslint/js");
const globals = require("globals");

module.exports = [
js.configs.recommended,
{
languageOptions: {
ecmaVersion: 2022,
globals: {
...globals.node,
...globals.es6,
},
},
},
{
files: ["tests/**"],
languageOptions: {
globals: {
...globals.mocha,
},
},
},
];
19 changes: 16 additions & 3 deletions package-lock.json

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

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"scripts": {
"test": "npm run lint && mocha --timeout 8000 tests",
"coverage": "nyc -x tests mocha --timeout 8000 tests",
"lint": "prettier -c . && ESLINT_USE_FLAT_CONFIG=false eslint ."
"lint": "prettier -c . && eslint ."
},
"repository": {
"type": "git",
Expand All @@ -33,6 +33,7 @@
},
"devDependencies": {
"eslint": "^9.1.1",
"globals": "^15.1.0",
"is-pdf": "^1.0.0",
"metalsmith": "^2.4.0",
"mocha": "^10.0.0",
Expand Down
5 changes: 0 additions & 5 deletions tests/.eslintrc.json

This file was deleted.