try running the code snippet below, and notice how after the confirmation dialog is dismissed, it re-appears for a second then discards itself again..
import SwiftUI
struct ContentView: View {
@State var dialog = false
@State var sheet = false
var body: some View {
VStack {
Button("Show Sheet") {
sheet = true
}
}
.sheet(isPresented: $sheet, content: {
Button("Show Dialog") {
dialog = true
}
.confirmationDialog(String(), isPresented: $dialog) {
Button("Some button 1") {
print("")
}
Button("Some button 2") {
print("")
}
}
})
}
}