Sample code is work fine but this is my result after using my own Admob code
Android show Error: The ad request was successful, but no ad was returned due to lack of ad inventory.
IOS show Error: No ads show
Did some body know why?

Same error here
There's a console.error in the handleAdFailedToLoad that causes the red screen. Remove the handler and it should no longer give you the red screen.
i have removed handleAdFailedToLoad but still redbox screen coming .. It is working perfectly in emulator .. but when debug apk run in real device issue still there !! Any idea to hide this error screen in real device permanently
it may take sometimes until Adsense activate your ad unit, the error will not show in release version but if you don't want to see the red screen look at your code you should find somewhere "console.error()" and change it to "console.log()"
@PuriaGithub thanks for reply . i searched no where console.error() found .. :(
@PuriaGithub thanks for reply . i searched no where console.error() found .. :(
Probably you are searching with brackets, just search console.error...
Actually it's in the prop that says "onAdFailedToLoad" ...
I commented "onAdFailedToLoad" tag in AdMobBanner Code and I don't get anymore red screen. But I don't see Admob in Android still..
You can check my code:
<AdMobBanner
adSize={adSize}
width={adWidth}
height={adHeight}
adUnitID={
Platform.OS === 'ios' ?
"YOUR_IOS_AD_CODE":
"YOUR_ANDROID_AD_CODE"
}
testDevices={[AdMobBanner.simulatorId]}
// onAdFailedToLoad={error => console.error(error)}
/>
Edit:
I commented "testDevices" tag and now I can see Admon in Android
You can check my code:
<AdMobBanner
adSize={adSize}
width={adWidth}
height={adHeight}
adUnitID={
Platform.OS === 'ios' ?
"YOUR_IOS_AD_CODE":
"YOUR_ANDROID_AD_CODE"
}
// testDevices={[AdMobBanner.simulatorId]}
// onAdFailedToLoad={error => console.error(error)}
/>
Most helpful comment
it may take sometimes until Adsense activate your ad unit, the error will not show in release version but if you don't want to see the red screen look at your code you should find somewhere "console.error()" and change it to "console.log()"