Installation Guide
Requirements
Flutter Environment
- Flutter: 3.3.0 or higher
- Dart: 2.17.0 or higher
Platform Requirements
| Platform | Requirements |
|---|---|
| Android | API 21+ (Android 5.0+) |
| iOS | 11.0 or higher |
Installation Steps
1. Add Dependency
Add the dependency to your pubspec.yaml file:
dependencies:
flutter:
sdk: flutter
iapp_player: ^1.0.0 # or use local path
# If using local version
# iapp_player:
# path: ./path/iapp_player
dev_dependencies:
flutter_test:
sdk: flutter
2. Platform-Specific Configuration
Android Configuration
Ensure minimum SDK version in android/app/build.gradle:
android {
compileSdkVersion 35
namespace 'com.example.yourapp'
defaultConfig {
minSdkVersion 21 // Important: Minimum API 21
targetSdkVersion 34
}
}
Add network permissions in android/app/src/main/AndroidManifest.xml:
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
iOS Configuration
Add network security configuration in ios/Runner/Info.plist:
<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>
Ensure iOS version in ios/Podfile:
platform :ios, '11.0'
Flutter Version Compatibility
This library strives to support at least the second-to-last version of Flutter (N-1 support).
However, due to major changes in Flutter versions, compatibility cannot be fully guaranteed, and major or minor version updates will be released when necessary.
More Documentation Resources
🎬 Player usage sample code - Use the player with sample code
📚 Complete API Parameter Documentation - Contains detailed explanations of all parameters
🏆 Advanced Function Documentation - Explore the advanced features of IAppPlayer
💡 If this documentation is not comprehensive enough, please check the detailed comments in the source code - We provide rich comments in the code, covering the usage, parameter descriptions, and examples of each API.
Important Notice
🚨 Important Notice
This library is not responsible for issues caused by the video_player library, it only serves as a UI wrapper on top of it.
That is: PlatformExceptions (platform exceptions) caused by video playback in the application are all caused by the video_player library.
Please submit related issues to the Flutter team.