You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Ricardo Corrie 1303040e17
(react-native-sdk) Adds `CONFERENCE_FOCUSED` and `CONFERENCE_BLURRED` events to the external and RN api (#13657)
1 年之前
..
android chroe(assets) copy sound files 1 年之前
.npmignore feat(rnsdk) add npm ignore file 1 年之前
.npmrc sdk(react-native-sdk): moved some dependencies to peer dependencies (#13498) 2 年之前
README.md sdk(react-native-sdk): rnsdk updates fixes (#13627) 1 年之前
index.tsx (react-native-sdk) Adds `CONFERENCE_FOCUSED` and `CONFERENCE_BLURRED` events to the external and RN api (#13657) 1 年之前
jitsi-meet-rnsdk.podspec chroe(assets) copy sound files 1 年之前
package-lock.json sdk(react-native-sdk): rnsdk updates fixes (#13627) 1 年之前
package.json sdk(react-native-sdk): revert version to 0.0.0 1 年之前
prepare_sdk.js fix(rnsdk) drop unnecessary Swift files and dependencies 1 年之前
sdk_instructions.js sdk(react-native-sdk): added script that updates app dependencies (#13516) 1 年之前
update_dependencies.js fix(rnsdk,deps) update dependencies 1 年之前

README.md

Jitsi Meet React Native SDK

Installation

Inside your project, run;

npm i @jitsi/react-native-sdk



Additionally, if not already installed, some dependencies will need to be added.

This can be done by running the following script:

node node_modules/@jitsi/react-native-sdk/update_dependencies.js

This will check and update all your dependencies.

Because of SVG use in react native, you need to update metro.config your project’s file:

const { getDefaultConfig } = require('metro-config');

module.exports = (async () => {
  const {
    resolver: {
      sourceExts,
      assetExts
    }
  } = await getDefaultConfig();

  return {
    transformer: {
      babelTransformerPath: require.resolve('react-native-svg-transformer'),
      getTransformOptions: async () => ({
        transform: {
          experimentalImportSupport: false,
          inlineRequires: true,
        },
      }),
    },
    resolver: {
      assetExts: assetExts.filter(ext => ext !== 'svg'),
      sourceExts: [...sourceExts, 'svg']
    }
  }
})();

iOS

Project Info.plist

  • Add a Privacy - Camera Usage Description
  • Add a Privacy - Microphone Usage Description

General

  • Signing & capabilites:
    • Add Background modes
      • Audio
      • Voice over IP
      • Background fetch

Run;

cd ios && pod install && cd ..

Android

  • In your build.gradle have at least minSdkVersion = 24
  • In android/app/src/debug/AndroidManifest.xml and android/app/src/main/AndroidManifest.xml, under the </application> tag, include xml <uses-permission android:name="android.permission.RECORD_AUDIO" /> <uses-permission android:name="android.permission.CAMERA" />

If you want to test all the steps before applying them to your app, you can check our React Native SDK sample app here: https://github.com/jitsi/jitsi-meet-sdk-samples/tree/master/react-native

Using JWT tokens

  • If you are planning to use tokens or another domain you can do that by updating the following props, as shown below.
  • For example: javascript <JitsiMeeting room={'ThisIsNotATestRoomName'} serverURL={'https://meet.jit.si/'} token={'dkhalhfajhflahlfaahalhfahfsl'} />