Skip to content
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

Use ReactDOM.createRoot instead of ReactDOM.render #5627

Merged
merged 3 commits into from
Jun 12, 2023
Merged

Conversation

rithviknishad
Copy link
Member

@rithviknishad rithviknishad commented Jun 8, 2023

WHAT

🤖 Generated by Copilot at c90e2f8

Switched the app to use React concurrent mode for better performance and user experience. Modified src/index.tsx to use the new API.

Proposed Changes

References:

@coronasafe/care-fe-code-reviewers @coronasafe/code-reviewers

Merge Checklist

  • Add specs that demonstrate bug / test a new feature.
  • Update product documentation.
  • Ensure that UI text is kept in I18n files.
  • Prep screenshot or demo video for changelog entry, and attach it to issue.
  • Request for Peer Reviews
  • Completion of QA

HOW

🤖 Generated by Copilot at c90e2f8

  • Enable concurrent mode for the app by using the experimental createRoot API from ReactDOM (link, link)
  • Update the index file to import the createRoot function from react-dom/experimental instead of the default ReactDOM (link)
  • Replace the ReactDOM.render call with the createRoot.render call, which returns a root object that can be used to update or unmount the app (link)

@vercel
Copy link

vercel bot commented Jun 8, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
care-storybook ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 10, 2023 2:48am

@netlify
Copy link

netlify bot commented Jun 8, 2023

Deploy Preview for care-egov-staging ready!

Name Link
🔨 Latest commit b469c55
🔍 Latest deploy log https://app.netlify.com/sites/care-egov-staging/deploys/6483e42493a71500086afd59
😎 Deploy Preview https://deploy-preview-5627--care-egov-staging.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@github-actions github-actions bot added the cypress failed pull request with cypress test failure label Jun 8, 2023
@github-actions github-actions bot removed the cypress failed pull request with cypress test failure label Jun 10, 2023
@nihal467
Copy link
Member

@khavinshankar I tested the normal functionality, can you review and merge it

@khavinshankar khavinshankar merged commit 615c7a5 into develop Jun 12, 2023
@khavinshankar khavinshankar deleted the fix-5625 branch June 12, 2023 12:22
@github-actions
Copy link

@rithviknishad We truly appreciate your efforts. Thank you for taking the time to contribute; this is a very valuable contribution to us 🥇. We always welcome your contribution 🙂, so feel free to contribute to anything anytime, and never lose that spirit of innovation 🙌.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ReactDOM.render is no longer supported in React 18. Behaving as React 17.
3 participants