I was playing around with SwiftUI and want to be able to come back to the previous view when tapping a button, the same we use popViewController inside a
popViewController
In the destination pass the view you want to redirect, and inside block pass data you to pass in another view.
NavigationLink(destination: "Pass the particuter View") { Text("Push") }