diff --git a/packages/eslint-config-smarthr/configs/react.js b/packages/eslint-config-smarthr/configs/react.js index 6b6b310a..49edbc90 100644 --- a/packages/eslint-config-smarthr/configs/react.js +++ b/packages/eslint-config-smarthr/configs/react.js @@ -20,8 +20,10 @@ export default [ languageOptions: { parserOptions: { ecmaFeatures: { - jax: true, + jsx: true, }, + // https://github.com/jsx-eslint/eslint-plugin-react/blob/e6b5b41191690ee166d0cca1e9db27092b910f03/index.js#L86 + jsxPragma: null, // for @typescript/eslint-parser }, }, settings: { @@ -82,6 +84,9 @@ export default [ 'react/prop-types': 'off', 'react/style-prop-object': 'error', 'react/void-dom-elements-no-children': 'error', + // https://github.com/jsx-eslint/eslint-plugin-react/blob/e6b5b41191690ee166d0cca1e9db27092b910f03/index.js#L89 + 'react/react-in-jsx-scope': 'off', + 'react/jsx-uses-react': 'off' } } ] diff --git a/packages/eslint-config-smarthr/test/__snapshots__/snapshot.test.js.snap b/packages/eslint-config-smarthr/test/__snapshots__/snapshot.test.js.snap index c72b10ab..e4abd836 100644 --- a/packages/eslint-config-smarthr/test/__snapshots__/snapshot.test.js.snap +++ b/packages/eslint-config-smarthr/test/__snapshots__/snapshot.test.js.snap @@ -1193,10 +1193,10 @@ exports[`should match ESLint Configuration snapshot 1`] = ` "parser": "typescript-eslint/parser@8.19.1", "parserOptions": { "ecmaFeatures": { - "jax": true, "jsx": true, }, "ecmaVersion": 2018, + "jsxPragma": null, "sourceType": "module", }, "sourceType": "module", @@ -2212,7 +2212,7 @@ exports[`should match ESLint Configuration snapshot 1`] = ` 0, ], "react/jsx-uses-react": [ - 2, + 0, ], "react/jsx-uses-vars": [ 2, @@ -2287,7 +2287,7 @@ exports[`should match ESLint Configuration snapshot 1`] = ` 0, ], "react/react-in-jsx-scope": [ - 2, + 0, ], "react/require-render-return": [ 2,