This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import UIKit | |
import AgoraUIKit_iOS | |
class ViewController: UIViewController { | |
var agoraView: AgoraVideoViewer? | |
override func viewDidLoad() { | |
super.viewDidLoad() | |
self.agoraView? = AgoraVideoViewer( | |
connectionData: AgoraConnectionData( | |
appId: <#Agora App ID#>, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
agoraView.join( | |
channel: "test", as: .broadcaster, fetchToken: true | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let agoraSettings = AgoraSettings() | |
agSettings.tokenURL = "https://<heroku url>" | |
agoraView = AgoraVideoViewer( | |
connectionData: AgoraConnectionData( | |
appId: <#Agora App ID#> | |
), | |
agoraSettings: agoraSettings | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apply plugin: 'kotlin-kapt' | |
apply plugin: 'dagger.hilt.android.plugin' | |
android { | |
// As Hilt uses Java 8 features, enable Java8 in app | |
compileOptions { | |
sourceCompatibility JavaVersion.VERSION_1_8 | |
targetCompatibility JavaVersion.VERSION_1_8 | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
buildscript { | |
... | |
ext.hilt_version = '2.33-beta' | |
dependencies { | |
... | |
classpath "com.google.dagger:hilt-android-gradle-plugin:$hilt_version" | |
} | |
} |