what should I change? I am trying to make rewarded ad in swiftui
Asked
Active
Viewed 251 times
1 Answers
1
RewardedAdView
should be a struct
, not a class
. If you need an NSObject
subclass to use as a delegate or for the target/action pattern, make it the Coordinator
type of RewardedAdView
.
Watch Integrating SwiftUI from WWDC 2019 for an explanation of how to implement a Coordinator
class.

rob mayoff
- 375,296
- 67
- 796
- 848