<aside> 💡 ChannelTalk SDK does not officially support Flutter. And, it's not optimized for Flutter.
This guide is not an official support document, so it may differ from the latest version. This guide was written in the following environment:
Flutter : 1.22.2 Android : minSdk 16 / targetSdk 29 / compileSdk 29 AndroidStudio : Android Studio 4.0.1 Build #AI-193.6911.18.40.6626763 Xcode : 12.0 (12A7209) CocoaPod : 1.10.0.rc.1 Channel SDK - Android : 8.0.0 Channel SDK - iOS : 8.0.2
</aside>
Basically, it is the same as the native SDK installation.
Please refer to the link for more details.
android {
...
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
}
Add the following to your app's build.gradle
.
dependencies {
implementation 'com.zoyi.channel:plugin-android:$[version]'
// If you already set FCM in your project, skip this dependency.
implementation 'com.zoyi.channel:plugin-android-fcm:$[version]'
}
If you are using Proguard, add the following to your proguard configuration.
-keep class com.zoyi.**{
*;
}
-dontwarn com.zoyi.**
If an error related to Multidex occurs, you need to set up Multidex.