iOS -How to Add GADBannerView to UICollectionReusableView
问题 I'm adding my bannerView inside a collectionView header. It won't let me set the bannerView.rootViewController as self to the headerView because it's not a UIViewController. I can always implement the required properties inside the viewController that has the collectionView but then how do I load the bannerView? class HeaderView: UICollectionReusableView { var bannerView: GADBannerView = { let view = GADBannerView() view.translatesAutoresizingMaskIntoConstraints = false return view }()