Files
Q-A_test/tooling/eslint/react.js
T
SDI 12e4f17b62
CI / typecheck (push) Successful in 1m8s
CI / format (push) Failing after 1m6s
CI / lint (push) Failing after 49s
CI / test (push) Failing after 1m8s
first commit
2026-07-15 18:05:12 +09:00

31 lines
843 B
JavaScript

import reactPlugin from 'eslint-plugin-react';
import compilerPlugin from 'eslint-plugin-react-compiler';
import hooksPlugin from 'eslint-plugin-react-hooks';
/** @type {Awaited<import('typescript-eslint').Config>} */
export default [
{
files: ['**/*.ts', '**/*.tsx'],
plugins: {
react: reactPlugin,
'react-compiler': compilerPlugin,
'react-hooks': hooksPlugin,
},
rules: {
...reactPlugin.configs['jsx-runtime'].rules,
...hooksPlugin.configs.recommended.rules,
'react/prop-types': 'off',
'react/jsx-key': 'error',
'react-hooks/exhaustive-deps': 'off',
'react/display-name': 'off',
'react-hooks/rules-of-hooks': 'off',
'react-compiler/react-compiler': 'error',
},
languageOptions: {
globals: {
React: 'writable',
},
},
},
];