Skip to content

Commit bb64df6

Browse files
committed
[New] jsx-runtime: set parserOptions.jsxPragma for @typescript-eslint/parser
See typescript-eslint/typescript-eslint#3788 (comment)
1 parent 130afb1 commit bb64df6

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ This change log adheres to standards from [Keep a CHANGELOG](http://keepachangel
1111
* [`jsx-no-target-blank`]: add `forms` option ([#1617][] @jaaberg)
1212
* [`jsx-pascal-case`]: add `allowLeadingUnderscore` option ([#3039][] @pangaeatech)
1313
* [`no-children-prop`]: Add `allowFunctions` option ([#1903][] @alexzherdev)
14+
* [`jsx-runtime`]: set `parserOptions.jsxPragma` for `@typescript-eslint/parser` ([e382d3d3][] @ljharb)
1415

1516
### Fixed
1617
* component detection: use `estraverse` to improve component detection ([#2992][] @Wesitos)
@@ -32,6 +33,7 @@ This change log adheres to standards from [Keep a CHANGELOG](http://keepachangel
3233
* [Tests] add weekly scheduled smoke tests ([#2963][] @AriPerkkio)
3334
* [Docs] improve instructions for `jsx-runtime` config ([#3052][] @ljharb)
3435

36+
[e382d3d3]: https://github.com/yannickcr/eslint-plugin-react/commit/e382d3d3283fcdaf0ae34662554bfee157a2fc3b
3537
[#3052]: https://github.com/yannickcr/eslint-plugin-react/issues/3052
3638
[#3051]: https://github.com/yannickcr/eslint-plugin-react/pull/3051
3739
[#3049]: https://github.com/yannickcr/eslint-plugin-react/pull/3049

index.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,8 @@ module.exports = {
168168
parserOptions: {
169169
ecmaFeatures: {
170170
jsx: true
171-
}
171+
},
172+
jsxPragma: null // for @typescript/eslint-parser
172173
},
173174
rules: {
174175
'react/react-in-jsx-scope': 0,

0 commit comments

Comments
 (0)