我正在尝试制作此广告的演示。当我按照本教程进行操作时。收到此错误使用未声明的类型“GADUnifiedNativeAdLoaderDelegate”。我正在使用最新版本的 GoogleMobileAds.framework。
应用委托
import Firebase
func application(_ application: UIApplication,
didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {
FirebaseApp.configure()
// Initialize the Google Mobile Ads SDK.
GADMobileAds.configure(withApplicationID: "ca-app-pub-3940256099942544~1458002511")
return true
}
视图控制器
import UIKit
import Firebase
import GoogleMobileAds
class ViewController: UIViewController, GADUnifiedNativeAdLoaderDelegate