@u3u/eslint-config
Version:
My ESLint config
40 lines (37 loc) • 1.03 kB
JavaScript
import { createRequire } from 'node:module';
const require = createRequire(import.meta.url);
import {
defineConfig
} from "./chunk-EDLRNWEK.mjs";
// src/react.ts
var react_default = defineConfig({
extends: ["plugin:react-hooks/recommended"],
plugins: ["react"],
rules: {
"react/function-component-definition": [
"warn",
{
namedComponents: "arrow-function",
unnamedComponents: "arrow-function"
}
],
"react/jsx-boolean-value": "warn",
"react/jsx-key": "warn",
"react/jsx-newline": ["warn", { allowMultilines: true, prevent: true }],
"react/jsx-sort-props": "warn",
"react/no-unknown-property": "off",
"react/prefer-stateless-function": "warn",
// 'react/jsx-handler-names': 'warn',
// 'react/jsx-no-useless-fragment': 'warn',
"react/self-closing-comp": ["warn", { component: true, html: true }],
"react/style-prop-object": "warn"
},
settings: {
react: {
version: "detect"
}
}
});
export {
react_default as default
};