if let js = OTPublishersHeadlessSDK.shared.getOTConsentJSForWebView() {
// Pass JS from SDK method to a custom WebView script
let script = WKUserScript(source: js, injectionTime: .atDocumentStart, forMainFrameOnly: false)
// Add the custom WebView script to WebView controller
config.userContentController.addUserScript(script)
}
https://webkit.org/blog/9674/new-webkit-features-in-safari-13/
suggested implementation to pass the consent is:
https://developer.onetrust.com/onetrust/docs/passing-consent-to-webview-ios-tvos