Use strict concurrency checking in Xcode 14 to find misuses with Swift concurrency. Cleanup files and rearrange them along with fixing comment headers. Signed-off-by: kingbri <bdashore3@proton.me>
27 lines
547 B
Swift
27 lines
547 B
Swift
//
|
|
// WebView.swift
|
|
// Ferrite
|
|
//
|
|
// Created by Brian Dashore on 7/17/22.
|
|
//
|
|
|
|
import SwiftUI
|
|
import WebKit
|
|
|
|
struct WebView: UIViewRepresentable {
|
|
var url: URL
|
|
|
|
func makeUIView(context: Context) -> WKWebView {
|
|
let webView = WKWebView()
|
|
let _ = webView.load(URLRequest(url: url))
|
|
return webView
|
|
}
|
|
|
|
func updateUIView(_ uiView: WKWebView, context: Context) {}
|
|
}
|
|
|
|
struct WebView_Previews: PreviewProvider {
|
|
static var previews: some View {
|
|
WebView(url: URL(string: "https://google.com")!)
|
|
}
|
|
}
|