struct ContentView_Previews: PreviewProvider {
static var previews: some View {
ContentView(pencilAction: () -> Void, fingerAction: () -> Void).environment(\.managedObjectContext, PersistenceController.preview.container.viewContext)
}
}
How to pass void functions defined in UIViewController(in UIHostingController) for swiftUI button in ContentView