41 lines
1008 B
JavaScript
41 lines
1008 B
JavaScript
import globals from "globals";
|
|
import pluginJs from "@eslint/js";
|
|
import pluginReact from "eslint-plugin-react";
|
|
import pluginReactCompiler from "eslint-plugin-react-compiler";
|
|
|
|
/** @type {import("eslint").Linter.Config[]} */
|
|
export default [
|
|
{ ignores: [
|
|
"node_modules/**",
|
|
"dist/**",
|
|
"build/**",
|
|
"dev-dist/**",
|
|
"**/trello-board/dnd/**" // Exclude third-party DnD library
|
|
] },
|
|
{
|
|
files: ["**/*.{js,mjs,cjs,jsx}"]
|
|
},
|
|
{ languageOptions: { globals: globals.browser } },
|
|
pluginJs.configs.recommended,
|
|
{
|
|
...pluginReact.configs.flat.recommended,
|
|
settings: {
|
|
react: { version: "detect" }
|
|
},
|
|
rules: {
|
|
...pluginReact.configs.flat.recommended.rules,
|
|
"react/prop-types": 0,
|
|
"react/no-children-prop": 0 // Disable react/no-children-prop rule
|
|
}
|
|
},
|
|
pluginReact.configs.flat["jsx-runtime"],
|
|
{
|
|
plugins: {
|
|
"react-compiler": pluginReactCompiler
|
|
},
|
|
rules: {
|
|
"react-compiler/react-compiler": "error"
|
|
}
|
|
}
|
|
];
|