React Native Zoom US 项目教程

React Native Zoom US 项目教程

react-native-zoom-us项目地址:https://gitcode.com/gh_mirrors/re/react-native-zoom-us

1. 项目的目录结构及介绍

react-native-zoom-us/
├── android/
│   ├── app/
│   ├── build.gradle
│   ├── settings.gradle
│   └── ...
├── ios/
│   ├── react-native-zoom-us/
│   ├── react-native-zoom-us.xcodeproj/
│   └── ...
├── src/
│   ├── index.ts
│   ├── native.ts
│   ├── video-view.tsx
│   └── ...
├── .eslintrc
├── .gitattributes
├── .gitignore
├── .npmignore
├── CHANGELOG.md
├── LICENSE
├── README.md
├── RNZoomUs.podspec
├── package-lock.json
├── package.json
└── tsconfig.json

目录结构介绍

  • android/: 包含 Android 项目的相关文件和配置。
  • ios/: 包含 iOS 项目的相关文件和配置。
  • src/: 包含项目的源代码文件。
    • index.ts: 项目的入口文件。
    • native.ts: 与原生代码交互的文件。
    • video-view.tsx: 视频视图组件。
  • .eslintrc: ESLint 配置文件。
  • .gitattributes: Git 属性配置文件。
  • .gitignore: Git 忽略文件配置。
  • .npmignore: npm 忽略文件配置。
  • CHANGELOG.md: 项目更新日志。
  • LICENSE: 项目许可证。
  • README.md: 项目说明文档。
  • RNZoomUs.podspec: CocoaPods 配置文件。
  • package-lock.json: npm 依赖锁定文件。
  • package.json: 项目依赖和脚本配置文件。
  • tsconfig.json: TypeScript 配置文件。

2. 项目的启动文件介绍

index.ts

index.ts 是项目的入口文件,负责初始化和导出主要的模块和功能。以下是该文件的主要内容:

import ZoomUs from 'react-native-zoom-us';

// 初始化
await ZoomUs.initialize({
  jwtToken: 'your_jwt_token'
});

// 初始化并配置
await ZoomUs.initialize({
  jwtToken: 'your_jwt_token',
  domain: 'zoom.us'
}, {
  disableShowVideoPreviewWhenJoinMeeting: true,
  enableCustomizedMeetingUI: true
});

// 启动会议
await ZoomUs.startMeeting({
  userName: 'Johny',
  meetingNumber: '12345678',
  zoomAccessToken: 'zak',
  userType: 2 // 可选
});

// 加入会议
await ZoomUs.joinMeeting({
  userName: 'Johny',
  meetingNumber: '12345678'
});

3. 项目的配置文件介绍

package.json

package.json 文件包含了项目的依赖、脚本和其他配置信息。以下是该文件的主要内容:

{
  "name": "react-native-zoom-us",
  "version": "6.18.0",
  "description": "React Native wrapper for ZoomUS SDK",
  "main": "src/index.ts",
  "scripts": {
    "android": "react-native run-android",
    "ios": "react-native run-ios",
    "start": "react-native start",
    "test": "jest",
    "lint": "eslint ."
  },
  "dependencies": {
    "react": "17.0.2",
    "react-native": "0.72.2",
    "react-native-zoom-us": "6.18.0"
  },
  "devDependencies": {
    "@babel/core": "^7.12.9",
    "@babel/runtime": "^7.12.5",
    "@react-native-community/eslint-config": "^2.0.0",
    "babel-jest": "^26.6.3",
    "eslint": "^7.14.0",
    "jest": "^26.6

react-native-zoom-us项目地址:https://gitcode.com/gh_mirrors/re/react-native-zoom-us

  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

娄佳淑Floyd

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值