-
Notifications
You must be signed in to change notification settings - Fork 0
/
eslint.config.mjs
46 lines (45 loc) · 933 Bytes
/
eslint.config.mjs
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 eslint from '@eslint/js'
import * as mdx from 'eslint-plugin-mdx'
import * as react from 'eslint-plugin-react'
import tailwind from 'eslint-plugin-tailwindcss'
import globals from 'globals'
export default [
eslint.configs.recommended,
{
plugins: {
react
},
languageOptions: {
parserOptions: {
ecmaFeatures: {
jsx: true
}
},
globals: {
...globals.browser,
...globals.node
}
},
rules: {
'react/react-in-jsx-scope': 'off',
'react/no-unescaped-entities': 'off',
'no-unused-vars': 'off'
}
},
{
...mdx.flat,
processor: mdx.createRemarkProcessor({
lintCodeBlocks: true,
languageMapper: {}
})
},
{
...mdx.flatCodeBlocks,
rules: {
...mdx.flatCodeBlocks.rules,
'no-var': 'error',
'prefer-const': 'error'
}
},
...tailwind.configs['flat/recommended']
]