Skip to content

fix(web-reporter-ui): depend on react-dom 18 - #391

Merged
AlecColas merged 1 commit into
mainfrom
fix/web-reporter-ui-react-dom
Oct 16, 2026
Merged

AlecColas merged 1 commit into
mainfrom
fix/web-reporter-ui-react-dom

Conversation

@AlecColas

Copy link
Copy Markdown
Contributor

Why

@perf-profiler/web-reporter-ui depends on react@^18.0.0 but not on react-dom, which MUI requires as a peer dependency. When installing it from npm, npm picks the latest react-dom that satisfies MUI's peer range, react-dom@19, which itself requires react@19:

npm warn ERESOLVE overriding peer dependency
npm warn While resolving: react-dom@19.3.1
npm warn Found: react@18.3.1
npm warn   react@"^18.0.0" from @perf-profiler/web-reporter-ui@0.16.1

The published 0.16.1 already has this conflict, and the MUI 9 upgrade keeps accepting react-dom@19. The package gets ~12k downloads a month, so fixing it before the next release.

What

Declare react-dom with the same range as react (^18.0.0). The lockfile only adds the range to the existing react-dom@18.3.1 entry.

Tested

  • yarn test: 60 tests, 22 snapshots, lint and build pass.
  • Packed every package and installed it from the tarballs in an empty project, like an npm user:
    • web-reporter-ui: react@18.3.1 + react-dom@18.3.1, no peer conflict (was react-dom@19.3.1 before)
    • measure and e2e: unchanged compared to the published versions
  • Generated a web report with the packed web-reporter CLI and rendered it in Chromium: 4 charts, metric rows expand, no JS errors.

🤖 Generated with Claude Code

web-reporter-ui depends on react 18 but not on react-dom, which MUI
requires as a peer dependency. npm then installs the latest react-dom that
satisfies MUI's peer range: react-dom 19, which requires react 19, so
installing @perf-profiler/web-reporter-ui from npm gives a conflicting
react/react-dom pair (`npm warn ERESOLVE overriding peer dependency`).
The published 0.16.1 already has this conflict, and MUI 9 keeps accepting
react-dom 19.

Declare react-dom with the same range as react.

Verified by packing the packages and installing them from the tarballs in
an empty project: web-reporter-ui now gets react 18.3.1 and react-dom
18.3.1 without peer conflicts, and the generated web report renders with
no JS errors. The installs of measure and e2e are unchanged.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@netlify

netlify Bot commented Oct 16, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for flashlight-docs canceled.

Name Link
🔨 Latest commit 3216516
🔍 Latest deploy log https://app.netlify.com/projects/flashlight-docs/deploys/6ad1da64101219aa4b1e1301

@AlecColas
AlecColas merged commit 37c5063 into main Oct 16, 2026
5 checks passed
@AlecColas
AlecColas deleted the fix/web-reporter-ui-react-dom branch October 16, 2026 08:09
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.

1 participant