Skip to content

Instantly share code, notes, and snippets.

@IsaAliev
Created August 12, 2021 17:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save IsaAliev/275fe597800714d571487b262f0f1bca to your computer and use it in GitHub Desktop.
Save IsaAliev/275fe597800714d571487b262f0f1bca to your computer and use it in GitHub Desktop.
struct ModalView: View {
let dismiss: () -> Void
var body: some View {
VStack {
Text("This is modal view")
.padding()
Button("Close") {
withAnimation {
dismiss()
}
}.padding()
}
.background(Color.white)
.cornerRadius(10)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment