initializeAds

suspend fun initializeAds(appOpenUnitId: String, disableNativeValidator: Boolean = false)(source)

Initializes ads from the host-manifest AdMobAppIdDataSource and observes the shared AdsSettingsRepository.adsEnabled, so enabling ads later can initialize the SDK without a process restart. Missing or invalid app IDs skip initialization; no fallback publisher ID is supplied.

Hosts must use this controller rather than initializing the Mobile Ads SDK separately. Use disableNativeValidator to configure native-ad validation.