如何将Ionic+Phaser游戏中AdMob横幅尺寸从SMART_BANNER改为BANNER?
Hey there! Switching the banner size is straightforward with the AdMob-Plus plugin—here's exactly what you need to do:
Update your banner show configuration
The default banner size isSMART_BANNER, so you just need to explicitly add thesizeparameter to youradmob.banner.show()call and set it to'BANNER'.Here's your modified code snippet:
admob.banner.show({ id: { ios: 'ca-app-pub-xxx~xxx', android: 'ca-app-pub-xxx~xxx' // Pro tip: Add your Android ad ID here too for full cross-platform support }, size: 'BANNER' // This is the key line to override the default size });Verify the change
After updating the code, rebuild and test your app on your target platforms. The banner should now render as the standard BANNER size instead of the responsive SMART_BANNER.For future reference, other valid size options you might use include
'LARGE_BANNER','MEDIUM_RECTANGLE', or'FULL_BANNER'—all align with Google's official AdMob banner size specifications.
内容的提问来源于stack exchange,提问作者Lukas B

