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

Migrate to React 18 #6686

Open
1 of 7 tasks
ToppleTheNun opened this issue Mar 26, 2024 · 2 comments
Open
1 of 7 tasks

Migrate to React 18 #6686

ToppleTheNun opened this issue Mar 26, 2024 · 2 comments

Comments

@ToppleTheNun
Copy link
Contributor

ToppleTheNun commented Mar 26, 2024

List of things that need to be done to migrate to React 18:

  • Find an alternative to AutoSizer from react-virtualized
    • This is due to react-virtualized not being updated to use React 18 types
    • react-virtualized-auto-sizer is by the same person, is updated, and is 1:1 API compatible. likely the easiest update.
  • Find an alternative to the table rendering from react-virtualized
    • This is due to react-virtualized not being updated to use React 18 types
    • Only thing left using this is EventsTab and this could probably swap to Tanstack Virtual
  • Find an alternative to react-toggle
    • This is due to react-toggle not being updated to use React 18 types
  • Update or find an alternative to @wowanalyzer/react-tooltip-lite
    • This is due to @wowanalyzer/react-tooltip-lite not being updated to use React 18 types and the functions used within aren't necessarily guaranteed to work in React 18 (haven't been able to test yet)
  • Improve usages of event.meta.inefficientCastReason
    • Some usages use MessageDescriptor from lingui while the type itself is explicitly React.ReactNode; this causes a problem in a couple of places like here: Ossuary.tsx
  • Fix Portal component
    • This makes TypeScript unhappy because ReactPortal is not assignable to ReactNode
  • Find an alternative to react-helmet
@ToppleTheNun
Copy link
Contributor Author

Looking at using Radix UI Primitives to replace react-toggle and react-tooltip-lite.

@ToppleTheNun
Copy link
Contributor Author

Working on a PR shortly to swap our current usage of <Toggle> to use @radix-ui/react-switch instead.

ToppleTheNun added a commit to ToppleTheNun/WoWAnalyzer that referenced this issue Mar 27, 2024
ToppleTheNun added a commit that referenced this issue Mar 27, 2024
ToppleTheNun added a commit that referenced this issue Mar 28, 2024
ToppleTheNun added a commit that referenced this issue Apr 5, 2024
ToppleTheNun added a commit that referenced this issue Apr 9, 2024
github-merge-queue bot pushed a commit that referenced this issue Apr 10, 2024
* if the thumbnail response is a full URL, use it as-is

the new Blizzard API endpoints give us full URLs that are...fine.
they're headshots, we can use them.

open to discussion because they ARE different. its the difference
between the thumbnail image on a WCL character page and the full render
shown to the side.

* more compatibility updates for v2

- rankings needs className/specName now, so we set those for classic
  specs
- ranking structure changed, so handle that
- fix some spots i missed with thumbnail/avatar handling

i have NOT tested classic yet. that will likely need work

* switch to Vite over create-react-app

removes create-react-app and customize-cra setup in favor
of Vite setup, including sentry vite plugin.

* update dependencies

* fix TS2612 findings

* run prettier

* use babel to parse configs instead of trying to import them

our configs end up requiring a huge chunk of the codebase when eagerly
evaluated as part of an `import` statement, which has caused headaches
repeatedly.

so...i gave up and just used babel as a fancy macro system to parse out
the content that we needed to set up the e2e tests

* properly filter the tests like the old implementation

* don't try matching on spec name here

* fix undefined error when viewing w/ old server

* fix a few react "error" warnings that got changed to errors

* fix prettier error that snuck in

* re-add package that i accidentally deleted

* get e2e *actually* working

* 90% sure this works

* add the partition error to ignore list

Wrath got partitioned today

* bump sentry and TypeScript (#6679)

* bump sentry dependencies

* bump TypeScript to 5.4

* update dependencies in next branch (#6685)

* update dependencies

* fix prettier finding

* switch to react-virtualized-auto-sizer (#6689)

part of steps for #6686

* fix broken talent references in Holy Priest changelog

---------

Co-authored-by: David Smith <emallson@emallson.net>
Saeldur pushed a commit to Saeldur/WoWAnalyzer that referenced this issue Apr 18, 2024
…6709)

* if the thumbnail response is a full URL, use it as-is

the new Blizzard API endpoints give us full URLs that are...fine.
they're headshots, we can use them.

open to discussion because they ARE different. its the difference
between the thumbnail image on a WCL character page and the full render
shown to the side.

* more compatibility updates for v2

- rankings needs className/specName now, so we set those for classic
  specs
- ranking structure changed, so handle that
- fix some spots i missed with thumbnail/avatar handling

i have NOT tested classic yet. that will likely need work

* switch to Vite over create-react-app

removes create-react-app and customize-cra setup in favor
of Vite setup, including sentry vite plugin.

* update dependencies

* fix TS2612 findings

* run prettier

* use babel to parse configs instead of trying to import them

our configs end up requiring a huge chunk of the codebase when eagerly
evaluated as part of an `import` statement, which has caused headaches
repeatedly.

so...i gave up and just used babel as a fancy macro system to parse out
the content that we needed to set up the e2e tests

* properly filter the tests like the old implementation

* don't try matching on spec name here

* fix undefined error when viewing w/ old server

* fix a few react "error" warnings that got changed to errors

* fix prettier error that snuck in

* re-add package that i accidentally deleted

* get e2e *actually* working

* 90% sure this works

* add the partition error to ignore list

Wrath got partitioned today

* bump sentry and TypeScript (WoWAnalyzer#6679)

* bump sentry dependencies

* bump TypeScript to 5.4

* update dependencies in next branch (WoWAnalyzer#6685)

* update dependencies

* fix prettier finding

* switch to react-virtualized-auto-sizer (WoWAnalyzer#6689)

part of steps for WoWAnalyzer#6686

* fix broken talent references in Holy Priest changelog

---------

Co-authored-by: David Smith <emallson@emallson.net>
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

No branches or pull requests

1 participant