unified_ads 1.0.0
unified_ads: ^1.0.0 copied to clipboard
One unified Dart API for banner, interstitial and rewarded ads across AdMob, Unity, AppLovin MAX, LevelPlay, Facebook Audience Network, Start.io and InMobi.
1.0.0 #
Initial release.
UnifiedAdsfacade:init/isInitialized/dispose, safe on re-init and hot restart;- a broadcast
eventsstream; - a pluggable
logger, silent by default.
RewardedInterstitialAd(withRewardedInterstitialCallback) andAppOpenAd, behind the same waterfall, cache, frequency caps and callbacks. Networks without the format are skipped (today: AdMob has both, AppLovin MAX has app open).InterstitialAdandRewardedAd:load()/show()/isReady, every callback, andservedBy(the network that served the ad).BannerAd+UnifiedBannerWidget:- platform-view banners in standard, adaptive and inline sizes;
- anchored or inline placement;
forceNetworkand collapse-on-failure.
- Waterfall across networks with per-network timeouts and automatic fallback. The preload cache refills after close. Frequency capping per format.
- Declarative config:
AdConfigLoader(ads_config.json, per-platform IDs, errors with a JSON path);dart run unified_ads:generate_configturns a pubspecunified_ads:section into that asset, with--set-exit-if-changedfor CI.
- Consent and ATT:
gatherConsent/updateConsentwith anyConsentProvider;requestTrackingAuthorization/trackingAuthorizationStatus(the iOS ATT helper; weak-linked).
package:unified_ads/testing.dart: a scriptableFakeAdNetworkAdapterfor app tests.- The app never crashes because of an ad: every failure is an
AdError/AdResult.