These samples demonstrate how to use opentok-react-native to do video-calling in a React Native application.
-
This sample application shows how to display and hide an archiving indicator when archiving for the session starts and stops. Note that you start and stop archiving using the OpenTok REST API or the OpenTok server SDKs. See the OpenTok Archiving developer guide.
-
This sample application shows how to connect to an OpenTok session, publish a stream, and subscribe to multiple streams for both iOS and Android using the OpenTok React Native API.
-
This sample application shows how to arrange videos and to toggle the mic and camera in multiparty calls.
-
This sample application shows how to connect to an OpenTok session and implement OpenTok Signaling to create a text chat for both iOS and Android using the OpenTok React Native API.
-
This sample application shows how to toggle between publishing a screen-sharing stream and a camera feed stream. Note that the screen-sharing stream shares the entire contents of the screen, so the local publisher and subscriber views are hidden (
{width: 0, height: 0}
) when publishing the screen-sharing stream (so they don't appear in the published stream).
For details on each sample, see the README.md file in each sample directory.
-
Install node.js
-
Install Watchman:
brew install watchman
-
Install React Native CLI:
npm install -g react-native-cli
-
Install and update Xcode (you will need a Mac)
- React Native iOS installation instructions
- Install and update Android Studio
- React Native Android installation instructions
-
Clone this repo.
-
In your terminal, change your directory to the sample project you want:
cd Archiving/
cd BasicVideoChat/
cd Multiparty/
cd Signaling/
cd ScreenSharing/
-
Install the required node modules:
npm install
-
For iOS, install the Podfile's dependencies:
cd ios/ && pod install
-
In the App.js file, set the
apiKey
,sessionId
, andtoken
properties to your Vonage Video API key (project ID), a Vonage Video session ID, and a token for that session.
Interested in contributing? We ❤️ pull requests! See the Contribution guidelines.
We love to hear from you so if you have questions, comments or find a bug in the project, let us know! You can either:
- Open an issue on this repository
- See https://support.tokbox.com/ for support options
- Tweet at us! We're @VonageDev on Twitter
- Or join the Vonage Developer Community Slack
- Check out the Developer Documentation at https://tokbox.com/developer/