Skip to content

Commit 67110ad

Browse files
committed
feat: support js and jsx files in react projects
1 parent 0b150aa commit 67110ad

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/configs/react.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { isPackageExists } from 'local-pkg'
22
import { ensurePackages, interopDefault, toArray } from '../shared'
3-
import { GLOB_TS, GLOB_TSX } from '../constants/glob'
3+
import { GLOB_JS, GLOB_JSX, GLOB_TS, GLOB_TSX } from '../constants/glob'
44
import type {
55
OptionsFiles,
66
OptionsOverrides,
@@ -21,7 +21,7 @@ const NextJsPackages = ['next']
2121
export async function react(
2222
options: OptionsTypeScriptWithTypes & OptionsOverrides & OptionsFiles = {},
2323
): Promise<TypedFlatConfigItem[]> {
24-
const { files = [GLOB_TS, GLOB_TSX], overrides = {} } = options
24+
const { files = [GLOB_JS, GLOB_JSX, GLOB_TS, GLOB_TSX], overrides = {} } = options
2525

2626
await ensurePackages([
2727
'@eslint-react/eslint-plugin',

0 commit comments

Comments
 (0)