Last updated:
0 purchases
my target flutter
my_target_flutter #
Flutter plugin to use MyTarget Interstitial ads.
MyTarget documentation
SDK version #
MyTarget SDK version, used in plugin:
iOS: ^5.15.2 (GitHub
Android: ^5.15.2 (Maven)
Minimum requirements #
iOS 9.0 and higher.
Android 4.0 and newer (SDK 14).
Getting Started #
add my_target_flutter as a dependency in your pubspec.yaml file;
create an instance of MyTargetFlutter and initialise MyTargetSdk:
import 'package:my_target_flutter/my_target_flutter.dart';
final _plugin = MyTargetFlutter(isDebug: isDebug);
await _plugin.initialize();
copied to clipboard
create an instance of InterstitialAd and add an instanse of AdStatusListener to InterstitialAd:
final _interstitialAd = await _plugin.createInterstitialAd(yourSlotId);
_interstitialAd.addListener(AdStatusListener(
onAdLoaded: _onLoaded,
onDisplay: _onDisplay,
onClickOnAD: _onClickOnAD,
onVideoCompleted: _onVideoCompleted,
onDismiss: _onDismiss,
onNoAd: _onNoAd,
));
copied to clipboard
show ads when it is loaded:
void _onLoaded() {
_interstitialAd.show();
}
copied to clipboard
See MyTarget documentation for full information.
For personal and professional use. You cannot resell or redistribute these repositories in their original state.
There are no reviews.