Pakete, Repositories und App-Kategorien suchen

Cover von easy_admob_ads_flutter
Paketdetailsv2.0.3

easy_admob_ads_flutter

Ein einfaches und flexibles Flutter-Paket, um AdMob-Anzeigenformate mit minimalem Setup zu integrieren.

AndroidiOS
30-Tage-Downloads
388
Likes
8
Pub-Punkte
160

Paket installieren

flutter pub add easy_admob_ads_flutter

Paketübersicht

Aus öffentlichen Paketdaten erstellte Orientierung.

EasyAdmobAdsFlutter ist ein leichtgewichtiges Flutter-Paket, das die Integration von AdMob-Werbeformaten in mobile Anwendungen vereinfachen soll. Mit minimaler Einrichtung ermöglicht es Entwicklern, Banner-, Interstitial- und Belohnungsanzeigen schnell auf Android- und iOS-Plattformen zu implementieren. Das Paket abstrahiert komplexe Konfigurationsschritte und bietet eine intuitive API für die Werbemanagement. Es unterstützt Echtzeit-Laden von Anzeigen und liefert Callbacks zur Verfolgung von Benutzerinteraktionen, was es ideal für die Monetarisierung von Apps macht.

Anwendungsfälle

  • Monetarisierung mobiler Apps mit Banneranzeigen
  • Interstitielle Anzeigen zwischen App-Bildschirmen anzeigen
  • Implementierung von belohnenden Videoanzeigen für Nutzeranreize
  • AdMob ohne tiefgehendes plattformspezifisches Wissen integrieren
  • Schnelle Anzeigen-Tests während der Entwicklung aktivieren

Hauptmerkmale

  • Einfache Einrichtung mit wenigen Codezeilen
  • Unterstützung für mehrere AdMob-Werbetypen
  • Plattformübergreifende Kompatibilität (Android & iOS)
  • Eingebaute Ereignis-Listener für Anzeigeninteraktionen
  • Minimale Boilerplate-Anforderung

Geeignet für

  • Flutter-Entwickler neu im AdMob
  • Apps, die eine schnelle Anzeigenintegration benötigen
  • Projekte mit engen Entwicklungszeitrahmen
  • Entwickler, die langlebige Werbelösungen suchen
  • Bildung oder Hobby-App-Ersteller

Hinweise

  • Benötigt gültiges AdMob-Konto und Anzeigen-Einheiten-IDs
  • Abhängig vom Google Mobile Ads SDK
  • Für bestimmte Anzeigenarten könnten zusätzliche Berechtigungen erforderlich sein
  • Nicht geeignet für erweiterte Anpassungen jenseits der grundlegenden Anzeigenverwaltung
  • Geringe Dokumentation im Vergleich zum offiziellen SDK

Original-README

Originaler README-Schnappschuss aus dem verknüpften Quell-Repository. Aktuelle Inhalte finden Sie im Repository.

Stand With Palestine

Easy AdMob Integration for Flutter

pub package Pub Points Last Commit Pull Requests Code Size License

A simple, configurable Flutter wrapper for Google AdMob. One EasyAdMobAds.instance sets up the SDK, GDPR/UMP consent, and a global on/off switch for ads. All six ad formats are supported with their own controller or widget.

Show some ❤️ by giving the repo a ⭐ and liking 👍 the package on pub.dev!

Screenshots

Static AdMob Demo Animated AdMob Demo Static AdMob Demo

Features

  • Banner (adaptive, optionally collapsible)
  • Interstitial
  • Rewarded
  • Rewarded Interstitial
  • App Open (auto-preloaded and shown on app resume)
  • Native (small/medium templates)
  • GDPR/UMP consent flow, including the "privacy options" re-consent form
  • App Tracking Transparency (ATT) consent on iOS 14.5+, requested automatically during initialize()
  • Network connectivity awareness — ad requests pause while offline and resume as soon as connectivity returns

Getting started

1. Install
dependencies:
  easy_admob_ads_flutter: ^<latest_version>
2. Platform setup

Add your AdMob App ID:

Android — android/app/src/main/AndroidManifest.xml:

<meta-data
  android:name="com.google.android.gms.ads.APPLICATION_ID"
  android:value="ca-app-pub-xxxxxxxxxxxxxxxx~yyyyyyyyyy"/>

iOS — ios/Runner/Info.plist:

<key>GADApplicationIdentifier</key>
<string>ca-app-pub-xxxxxxxxxxxxxxxx~yyyyyyyyyy</string>
3. Initialize
void main() async {
  WidgetsFlutterBinding.ensureInitialized();

  await EasyAdMobAds.instance.initialize(
    config: const EasyAdsConfig(
      androidAdUnitIds: {
        AdType.banner: 'ca-app-pub-.../...',
        AdType.interstitial: 'ca-app-pub-.../...',
      },
      iosAdUnitIds: {
        AdType.banner: 'ca-app-pub-.../...',
        AdType.interstitial: 'ca-app-pub-.../...',
      },
      testDeviceIds: ['YOUR_TEST_DEVICE_ID'],
    ),
  );

  runApp(const MyApp());
}

Any AdType you don't configure automatically falls back to a Google test ad unit ID (with a warning logged), so the package works out of the box during development.

Usage

// Banner
const EasyBannerAd(collapsible: true, height: 100)

// Native
EasyNativeAd.medium()

// Interstitial
final interstitialAd = EasyInterstitialAd()..loadAd();
await interstitialAd.showAd();

// Rewarded
final rewardedAd = EasyRewardedAd(onRewardEarned: (reward) {
  // grant the reward
})..loadAd();
await rewardedAd.showAd();

// Rewarded Interstitial
final rewardedInterstitialAd = EasyRewardedInterstitialAd(onRewardEarned: (reward) {
  // grant the reward
})..loadAd();
await rewardedInterstitialAd.showAd();

// App Open — preloaded automatically; show it manually if you want:
await EasyAdMobAds.instance.appOpenAd?.showAdIfAvailable();

// Turn all ads on/off (e.g. after a "remove ads" purchase)
EasyAdMobAds.instance.adsEnabled = false;

// GDPR privacy options
if (EasyAdMobAds.instance.isPrivacyOptionsRequired) {
  EasyAdMobAds.instance.showPrivacyOptionsForm();
}

See the example/ app for a full demo screen with all ad types, the on/off switch, and the consent button wired up.

Author

Huzaib Sayyed

GitHub LinkedIn

Kategorien

Abhängigkeiten

Abhängigkeiten 6 Einträge

Quell-Repository

Projekte, die dieses Paket verwenden

Noch keine Daten verfügbar.