forked from udecode/plate
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patheslint.config.mjs
More file actions
44 lines (43 loc) · 1.08 KB
/
eslint.config.mjs
File metadata and controls
44 lines (43 loc) · 1.08 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
import tsParser from '@typescript-eslint/parser';
import { defineConfig } from 'eslint/config';
import reactHooks from 'eslint-plugin-react-hooks';
export default defineConfig([
{
ignores: [
'**/.pnpm-store/**',
'**/*.spec.*',
'**/node_modules/**',
'**/dist/**',
'**/.next/**',
'**/build/**',
'**/.turbo/**',
'**/coverage/**',
'**/templates/**',
'**/.contentlayer/**',
'**/public/**',
'**/*.config.*',
'**/*.d.ts',
'.changeset/**',
'tooling/**',
],
},
// React Hooks config for apps/www (React 19 with React Compiler)
{
...reactHooks.configs.flat.recommended,
files: [
'apps/www/src/**/*.tsx',
'apps/www/src/**/use*.ts',
'packages/**/src/**/*.tsx',
'packages/**/src/**/use*.ts',
],
languageOptions: { parser: tsParser },
},
// Disable React Compiler rules for packages (React 18 compatibility)
{
files: ['packages/**'],
rules: {
'react-hooks/immutability': 'off',
'react-hooks/preserve-manual-memoization': 'off',
},
},
]);