I used to know this until Beta5 came along. Now it needs a PrimitiveButtonStyleConfiguration.Label but I am not sure how to initialise a PrimitiveButtonStyleConfiguration.Label? Previously we were able to put any old view as a Label. But not anymore.
Anyone knows how to create a button in SwiftUI Beta 5?
This works for me:
Button(action: {
print("hello")
}) {
Text("Hello")
}I just had to remove the
() -> PrimitiveButtonStyleConfiguration.Label inat the begining of the closure.