// // TestWebView.swift // WKWebKitAsyncTest // // Created by Richard Pineo on 5/16/25. // import SwiftUI import WebKit struct TestWebView: UIViewRepresentable { func updateUIView(_ uiView: WKWebView, context: Context) { let commandStr = "(function() {})();" uiView.callAsyncJavaScript(commandStr, in: nil, in: .page) { result in switch result { case let .failure(error): print(error) case .success: print ("success") } } } func makeUIView(context: Context) -> WKWebView { .init() } }