Thanks to visit codestin.com
Credit goes to github.com

Skip to content

chore: remove react imports #1867

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
May 31, 2022
Merged

Conversation

Kira-Pilot
Copy link
Member

resolves #1856

We no longer need to import React when using JSX.
Screen Shot 2022-05-27 at 4 32 46 PM

This is a big change so definitely let me know if you have concerns.

I will comment below on any functional changes to assist in review.

@Kira-Pilot Kira-Pilot requested a review from a team as a code owner May 27, 2022 20:39
@@ -114,6 +114,9 @@ rules:
react/jsx-curly-brace-presence:
- error
- children: ignore
# https://reactjs.org/blog/2020/09/22/introducing-the-new-jsx-transform.html#eslint
react/jsx-uses-react: "off"
react/react-in-jsx-scope: "off"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Turning off these ESLint rules (as suggested by React) so we don't hear it complain.

@@ -5,7 +5,7 @@
"forceConsistentCasingInFileNames": true,
"incremental": true,
"isolatedModules": true,
"jsx": "react",
"jsx": "react-jsx",
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This just informs React that we're using the new transform.

@Kira-Pilot Kira-Pilot merged commit dd55d45 into main May 31, 2022
@Kira-Pilot Kira-Pilot deleted the no-more-react-imports/kira-pilot branch May 31, 2022 14:01
kylecarbs pushed a commit that referenced this pull request Jun 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Quiet ESLint so we don't have to import React anymore
3 participants