EddyVerbruggen / nativescript-admob

NativeScript plugin to earn some precious :moneybag::moneybag: with ads by Google AdMob
MIT License
69 stars 26 forks source link

It doesn't work with Android 11 #94

Open pierreamgabriel opened 3 years ago

pierreamgabriel commented 3 years ago

Since nativescript-admob is still using play-service 17, it doesn't show any ads on Android 11. Play services 19.0.0 or above is required.

pierreamgabriel commented 3 years ago

Ok, the solution for this is to open nativescript-admob/platforms/android/include.gradle and change it from '17+' to '19+'. To be able to use '20+', you also need to set multiDexEnabled true in your app.gradle file. But with 20+, it'll throw the error: "builder.addTestDevice is not a function", so stick to 19+ until the developer makes the necessary changes to support the latest versions of play-services.