Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
swiftuiplayground
import UIKit
import PlaygroundSupport
import SwiftUI
struct ContentView: View {
var body: some View {
Text("Hello, world!")
}
}
let viewController = UIHostingController(rootView: ContentView())
PlaygroundPage.current.liveView = viewController
PlaygroundPage.current.needsIndefiniteExecution = true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment