File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
apps/website/content/docs/getting-started Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -6,12 +6,13 @@ description: Getting started with JavaScript setup
6
6
## Install
7
7
8
8
``` package-install copy
9
- npm install --save-dev eslint @eslint/js @eslint-react/eslint-plugin
9
+ npm install --save-dev globals eslint @eslint/js @eslint-react/eslint-plugin
10
10
```
11
11
12
12
## Setup
13
13
14
14
``` js title="eslint.config.js"
15
+ import globals from " globals" ;
15
16
import eslintJs from " @eslint/js" ;
16
17
import eslintReact from " @eslint-react/eslint-plugin" ;
17
18
import { defineConfig } from " eslint/config" ;
@@ -24,15 +25,16 @@ export default defineConfig([
24
25
eslintReact .configs .recommended ,
25
26
],
26
27
languageOptions: {
28
+ globals: {
29
+ ... globals .browser
30
+ }
27
31
parserOptions: {
28
32
ecmaFeatures: {
29
33
jsx: true ,
30
34
},
31
35
},
32
36
},
33
37
rules: {
34
- // Add `globals` if you need this rule
35
- " no-undef" : " off" ,
36
38
// Put rules you want to override here
37
39
" @eslint-react/prefer-shorthand-boolean" : " warn" ,
38
40
},
You can’t perform that action at this time.
0 commit comments