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

Upgrade to React 18 #1205

Open
1 task
sam-glendenning opened this issue Oct 20, 2022 · 1 comment · May be fixed by #1275
Open
1 task

Upgrade to React 18 #1205

sam-glendenning opened this issue Oct 20, 2022 · 1 comment · May be fixed by #1275
Labels
dependencies Pull requests that update a dependency file enhancement New feature or request

Comments

@sam-glendenning
Copy link
Contributor

sam-glendenning commented Oct 20, 2022

Description:
Should be tackled in conjunction with ral-facilities/datagateway#1445.

At present, we are running React v17.0.2. v18 has been out for some time now and we should upgrade to the latest stable version, which currently sits at v18.2.0.

React 18 brings a variety of improvements and changes. It's worth having a read of the official React 18 blog post to learn of the additions it has brought (some of these you may find useful going forward!).

Refer to the official React 18 migration guide while tackling this issue. It's important we eliminate any deprecated code that could interfere with the upgrade. For example:

image

And we don't want that, do we?

The only obstacle standing in React 18's way at the time this issue was created is the continuing use of Enzyme for tests (which aren't officially supported in React 17 and break entirely in React 18). Fortunately, work is underway to migrate all remaining Enzyme tests to React Testing Library. Once that work is completed, we can begin the upgrade to React 18.

Finally, all that's left to make sure of is that both SciGateway and DataGateway are upgraded to React 18 at the same time. This ensures all runs smoothly between the parent app and its plugins.

Acceptance criteria:

  • Upgraded to react ^18.2.0
@sam-glendenning sam-glendenning added enhancement New feature or request dependencies Pull requests that update a dependency file labels Oct 20, 2022
@sam-glendenning
Copy link
Contributor Author

sam-glendenning commented Oct 20, 2022

While tackling this issue, also make sure that the following dependencies are updated:
#1191
#1190
#1193
#1188

louise-davies added a commit that referenced this issue Apr 5, 2023
- also, upgrade other libraries to support react 18
and fix anything that broke immediately
@louise-davies louise-davies linked a pull request Apr 26, 2023 that will close this issue
3 tasks
joelvdavies added a commit that referenced this issue Apr 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant