-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patheslint.config.js
More file actions
46 lines (42 loc) · 1.41 KB
/
Copy patheslint.config.js
File metadata and controls
46 lines (42 loc) · 1.41 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
41
42
43
44
45
46
import js from "@eslint/js"
import pluginReact from "eslint-plugin-react"
import { defineConfig } from "eslint/config"
import globals from "globals"
import tseslint from "typescript-eslint"
export default defineConfig([
// Global ignores should be at the top level
{
ignores: [
"**/node_modules/**",
"**/dist/**",
"**/build/**",
"**/coverage/**",
"**/+types/**",
"**/.react-router/**",
"**/.api/**",
],
},
// Base configurations
js.configs.recommended,
tseslint.configs.recommended,
// This config is for projects using React 17's new JSX transform.
// It disables rules like `react/react-in-jsx-scope`.
{
files: ["**/*.{js,mjs,cjs,ts,jsx,tsx}"],
languageOptions: { globals: { ...globals.browser } },
rules: {
"no-empty-pattern": "off",
"no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": "off",
"@typescript-eslint/no-explicit-any": "off",
},
settings: { react: { version: "detect" } },
},
// Node에서 직접 실행하는 스크립트는 브라우저가 아닌 Node 전역을 쓴다
{
files: ["scripts/**/*.{js,mjs,cjs}"],
languageOptions: { globals: { ...globals.node } },
},
// Custom configurations for your project
pluginReact.configs.flat["jsx-runtime"],
])