fix(react,journeys): bump peer @modular-react/core to ^2.0.0#33
fix(react,journeys): bump peer @modular-react/core to ^2.0.0#33diogomiguel merged 1 commit intomainfrom
Conversation
`@modular-react/react@2.0.0` and `@modular-react/journeys@1.0.0` already require a 2.x core at runtime — lazy entry-points, the `EagerModuleEntryPoint | LazyModuleEntryPoint` union, and `resolveEntryComponent` all live in core 2.x — but the peer descriptors still pointed at `^1.2.0`. Consumers installing `journeys@1.0.0` against `core@^2.0.0` hit ERESOLVE; falling back to `--legacy-peer-deps` ends up dual-installing core (hoisted 2.x + nested 1.x under journeys), which fragments singletons (registry, defineEntry identity) at runtime. Same fix on `@modular-react/journeys` peer of `@modular-react/react` (`^1.2.0` → `^2.0.0`). Peer-descriptor correction, no behavior change.
|
ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (3)
📝 WalkthroughWalkthroughThis PR updates peer dependency ranges for ChangesVersion 2.0.0 Release Documentation and Peer Dependencies
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Possibly related PRs
Suggested labels
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Same peer-descriptor correction we did for journeys/react in #33, applied to all six router-modules packages. Testing packages also bump their peer of `@modular-react/journeys` from `^1.0.0` to `^1.0.1` to match the upstream peer correction. No behavior change.
Summary
@modular-react/react@2.0.0and@modular-react/journeys@1.0.0declare@modular-react/core: ^1.2.0, but both packages already require a 2.x core at runtime.^2.0.0and adds the same fix to journeys' peer of@modular-react/react.Unreleased.Why this matters for consumers
Trying to install
@modular-react/journeys@1.0.0against@modular-react/core@^2.0.0(the version that actually contains the lazy entry-point support journeys depends on) produces:The
--legacy-peer-deps/--forceworkarounds installed but produced a dual-copy resolution:That fragments
registry,defineEntryidentity, and any other singleton in core — calls from journeys' code (lazy resolution,JourneyOutletpreload) would be operating against a different core instance than the host app'sregistry.register(...). Hard to debug.The runtime code in journeys 1.0.0 already imports
EagerModuleEntryPoint | LazyModuleEntryPointandresolveEntryComponent— symbols introduced in core 2.0.0. The^1.2.0peer was just never bumped when the lazy work landed in #30. Same drift onreact@2.0.0's own peer of core.Verification
After this lands and ships (assuming via the workspace
release-same-versionflow), a consumer doing:resolves to a single hoisted
core@2.xeverywhere — no nested copies, noERESOLVE.Test plan
pnpm installat the workspace root still resolves cleanly (workspace deps useworkspace:*so the changed peer ranges don't affect internal resolution)git diffshows only peer ranges and the CHANGELOG entry — no behavior code touchedSummary by CodeRabbit
Behavior Changes
Dependencies