mirror of
https://github.com/sipeed/NanoKVM-USB.git
synced 2026-09-10 21:49:56 -05:00
28 lines
888 B
JavaScript
28 lines
888 B
JavaScript
import js from '@eslint/js';
|
|
import eslintConfigPrettier from 'eslint-config-prettier';
|
|
import reactHooksPlugin from 'eslint-plugin-react-hooks';
|
|
import reactRefreshPlugin from 'eslint-plugin-react-refresh';
|
|
import globals from 'globals';
|
|
import tseslint from 'typescript-eslint';
|
|
|
|
export default tseslint.config(
|
|
{ ignores: ['dist', 'node_modules'] },
|
|
{
|
|
files: ['**/*.{ts,tsx}'],
|
|
extends: [js.configs.recommended, ...tseslint.configs.recommended, eslintConfigPrettier],
|
|
languageOptions: {
|
|
ecmaVersion: 2020,
|
|
globals: globals.browser
|
|
},
|
|
plugins: {
|
|
'react-hooks': reactHooksPlugin,
|
|
'react-refresh': reactRefreshPlugin
|
|
},
|
|
rules: {
|
|
...reactHooksPlugin.configs.recommended.rules,
|
|
'@typescript-eslint/no-explicit-any': 'off',
|
|
'react-refresh/only-export-components': ['warn', { allowConstantExport: true }]
|
|
}
|
|
}
|
|
);
|