-
-
Notifications
You must be signed in to change notification settings - Fork 400
Closed
Description
Describe the bug
React bridge breaks when used with React 16 versions earlier than React 16.13.0. React 16.13.0 introduced the version prop (https://github.com/facebook/react/releases/tag/v16.13.0) which react-bridge uses in the isReact18 check:
const isReact18 = ReactDOM.version.startsWith("18");
When using React 16.12.0 this checks fails with:
Cannot read properties of undefined (reading 'startsWith')
Reproduction
https://github.com/CarltonHowell/react-16-17-bridge-demo
Used Package Manager
pnpm
System Info
System:
OS: macOS 14.7.4
CPU: (10) arm64 Apple M1 Pro
Memory: 1.43 GB / 32.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 20.10.0 - ~/.nvm/versions/node/v20.10.0/bin/node
Yarn: 1.22.21 - ~/.nvm/versions/node/v20.10.0/bin/yarn
npm: 10.2.3 - ~/.nvm/versions/node/v20.10.0/bin/npm
pnpm: 8.13.1 - ~/.nvm/versions/node/v20.10.0/bin/pnpm
Browsers:
Chrome: 134.0.6998.89
Safari: 18.3Validations
- Read the docs.
- Read the common issues list.
- Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- Make sure this is a Module federation issue and not a framework-specific issue.
- The provided reproduction is a minimal reproducible example of the bug.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels