-
Notifications
You must be signed in to change notification settings - Fork 2
FCE-2487: Override MediaStream #454
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR overrides TypeScript type definitions for MediaStream-related types in the mobile client to use the React Native WebRTC MediaStream type instead of the standard web MediaStream type. This fixes type inconsistencies where the mobile client was using MediaStreamWithURL interface workarounds.
Changes:
- Overrides return types of hooks (
useCamera,useMicrophone,useLivestreamViewer,useLivestreamStreamer,usePeers) to use RNMediaStream - Redefines types (
Track,PeerWithTracks,StreamerInputs,ConnectStreamerConfig,UseLivestreamViewerResult) to use RNMediaStream - Removes
MediaStreamWithURLinterface workarounds from example files - Adds entry point configuration to video-player example app
Reviewed changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| packages/mobile-client/src/index.ts | Overrides hook return types and redefines types to use React Native MediaStream instead of web MediaStream |
| examples/mobile-client/video-player/package.json | Adds main entry point configuration |
| examples/mobile-client/video-player/index.js | Creates entry point file that registers the root component |
| examples/mobile-client/video-player/app.json | Adds main entry point to Expo configuration |
| examples/mobile-client/video-player/components/FishjamPlayerViewer.tsx | Removes MediaStreamWithURL workaround, uses proper types |
| examples/mobile-client/video-player/components/FishjamPlayerStreamer.tsx | Removes MediaStreamWithURL workaround, uses proper types |
| examples/mobile-client/minimal-react-native/components/VideosGridItem.tsx | Removes MediaStreamWithURL workaround, removes TODOs, adds mirror prop |
| examples/mobile-client/fishjam-chat/components/VideosGrid.tsx | Removes MediaStreamWithURL workaround, adds mirror prop |
| examples/mobile-client/fishjam-chat/app/room/preview.tsx | Removes MediaStreamWithURL workaround, removes unused videoRoomEnv parameter |
| examples/mobile-client/fishjam-chat/app/livestream/viewer.tsx | Adds mirror prop to RTCView |
| examples/mobile-client/fishjam-chat/app/livestream/streamer.tsx | Removes MediaStreamWithURL workaround |
| examples/mobile-client/fishjam-chat/app/(tabs)/room.tsx | Removes videoRoomEnv from navigation params |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
examples/mobile-client/video-player/components/FishjamPlayerViewer.tsx
Outdated
Show resolved
Hide resolved
cbc5eae to
ef9295b
Compare
Description
Override types related to MediaStream to include MediaStream from RN.
Documentation impact
Types of changes
not work as expected)