sbugert/react-native-admob

Admob crashes whole app on production

Closed this issue · 1 comments

Im trying to debug my app using react-native run-android --variant=release and while opening app it totally crashes with error Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: undefined.

My code for displaying an add is the same as in docs.

<AdMobBanner adSize="banner" adUnitID="ca-app-pub-4093042818195907/********" testDevices={[ AdMobBanner.simulatorId ]} />

I linked this library using react-native link and I have specified my APP_ID in AndroidManifest.xml

make sure u update the AndroidManifest.xml, as described in the Google Mobile Ads SDK documentation.
https://developers.google.com/admob/android/quick-start#update_your_androidmanifestxml