Ionic not detect some cordova plugin


#1

Hello,

firstly i want to say thank for ionic it’s an staring tool :slight_smile:

actually i work on project and i try to add ads for this i use cordova-plugin-admob-free this plugin is installed :

config.xml

<plugin name="cordova-plugin-admob-free" spec="~0.9.0" />

package.json

  "cordovaPlugins": [
    "cordova-plugin-whitelist",
    "cordova-plugin-console",
    "cordova-plugin-statusbar",
    "cordova-plugin-splashscreen",
    "cordova-plugin-device",
    "cordova-plugin-admob-free",
    "ionic-plugin-keyboard"
  ],

but when i try to prepare and show ads ionic say :
Install the AdMobFree plugin: 'ionic plugin add cordova-plugin-admob-free’
Native: tried calling AdMobFree.show, but the AdMobFree plugin is not installed.

i have aleready try to resore (ionic restore), unistall plugin and reinstall
this is my fonction :

addAds(){
this.platform.ready().then(() => {
  this.admob.banner.config({
    id: 'app-id',
    isTesting: true,
  });
  this.admob.banner.prepare();
  this.admob.banner.show();
 });

}

I you got any idea about this ?

PS : Sorry for my poor english

Thanks


#2

Did you install the plugin with npm?


#3

Yes like this :
ionic plugin add --save cordova-plugin-admob-free npm install --save @ionic-native/admob-free


#4

Did you found any solution because I have the same problem?


#5

No sorry i had to remplace admob plugin free by admob pro