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

feat: upgrade eslint to v9.15 #753

Merged
merged 2 commits into from
Nov 23, 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
9 changes: 0 additions & 9 deletions .eslintrc

This file was deleted.

42 changes: 42 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
// @ts-check

import eslint from "@eslint/js";
import eslintPluginJest from "eslint-plugin-jest";
import json from "eslint-plugin-json";
import globals from "globals";

export default [
{
name: "base",
ignores: ["**/node_modules/**", "**/dist/**", "**/built/**"],
},
{
name: "eslint/recommended-with-overrides",
files: ["**/*.js"],
languageOptions: {
globals: {
...globals.node,
...globals.jest,
},
},
rules: {
...eslint.configs.recommended.rules,
"no-unused-vars": "warn",
"no-undef": "warn",
},
},
{
name: "jest/recommended",
files: ["**/*.test.{js,ts}"],
ignores: ["**/*.json"],
...eslintPluginJest.configs["flat/recommended"],
},
{
name: "json/recommended-with-comments",
files: ["**/*.json"],
...json.configs["recommended"],
rules: {
"json/*": ["warn", { allowComments: false }],
},
},
];
Loading