-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy patheslint.config.js
More file actions
40 lines (38 loc) · 1.1 KB
/
eslint.config.js
File metadata and controls
40 lines (38 loc) · 1.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
// @ts-check
import eslint from '@eslint/js';
import tsPlugin from '@typescript-eslint/eslint-plugin';
import tsParser from '@typescript-eslint/parser';
import * as airbnb from 'eslint-config-airbnb-typescript';
import * as eslintPluginReact from 'eslint-plugin-react';
import eslintPluginReactHooks from 'eslint-plugin-react-hooks';
import globals from 'globals';
export default [
{
files: ['**/*.{js,mjs,cjs,ts,jsx,tsx}'],
languageOptions: {
parser: tsParser,
ecmaVersion: 'latest',
sourceType: 'module',
globals: {
...Object.fromEntries(
Object.entries({
...globals.browser,
...globals.jest,
// 여기에 InputDeviceInfo 수동 등록
InputDeviceInfo: false,
}).map(([key, value]) => [key.trim(), value]),
),
},
},
plugins: {
'@typescript-eslint': tsPlugin,
react: eslintPluginReact,
'react-hooks': eslintPluginReactHooks,
},
rules: {
...eslint.configs.recommended.rules,
...tsPlugin.configs.recommended.rules,
...airbnb.rules,
},
},
];