Trouble With Build Android



to resume, i try to build my project into android and he tell me build fail because AdMob plugin i think but this is what they said :
compileDebugJava/Users/chocho/Desktop/Nabr/platforms/android/src/com/rjfun/cordova/plugin/ error: cannot find symbol
((ViewGroup) webView.getRootView()).addView(adViewLayout, params);
symbol: method getRootView()
location: variable webView of type CordovaWebView
/Users/chocho/Desktop/Nabr/platforms/android/src/com/rjfun/cordova/plugin/ error: cannot find symbol
ViewGroup parentView = (ViewGroup) webView.getParent();
symbol: method getParent()
location: variable webView of type CordovaWebView

By The way it s work fine on iOS i buld it and deploy it

Thank you


That’s normal java code of the plugin is only for Android.

Anyway, this is not an ionic issue, it’s a plugin issue and it seems to be a known one.

Basically they say; If you are using cordova CLI 5.0 (which is what ionic uses), please migrate to cordova-plugin-admobpro

ngCordova has {an issue about it]( so it seems that you should use and $cordovaGoogleAds