Only test ads work on Admob

Asked

Viewed 319 times

-1

I tried to add Admob to Ionic 4 with several web tutorials, but none are solving the error where only test ads are appearing when I put TRUE to isTesting. When I place FALSE and add the ad ID, it does not appear.

My Admob ID is already in package.json, I tested all kinds of Admob ads and none worked.

1 answer

0


Buddy, now the ad only works with the signed apk, don’t worry, when publishing your banner will appear in the app.

follows an example to help you:

 admob(){
    const bannerConfig: AdMobFreeBannerConfig = {      
      id:'xxxxxxxxxxxxxxxxxxxxxxxxxxx',
      isTesting: false,
      autoShow: true      
      };
      this.admobFree.banner.config(bannerConfig);
    
        this.admobFree.banner.prepare()
          .then(() => {
            if (this.infoNetwork.isConnect) {
            this.admobFree.banner.show().then(() => {
            }).catch(e => this.admobFree.banner.hide());
            }else{
              this.admobFree.banner.hide()
            }
          })
          .catch(e =>  this.admobFree.banner.hide());
  }

Browser other questions tagged

You are not signed in. Login or sign up in order to post.