[英]SwiftUI: navigate to a view without getting the back button
Hi im trying to navigate to a new view but dont want to use navigation link because i get the back button.嗨,我正在尝试导航到新视图,但不想使用导航链接,因为我得到了后退按钮。 I also want to use the flipHorisontal animation.我还想使用翻转水平 animation。 Is it possible to make this work in SwiftUI?是否可以在 SwiftUI 中进行这项工作?
struct ContentView: View {
var body: some View {
NavigationView {
VStack {
NavigationLink(destination: DetailView()) {
Text("Show Detail View")
}.navigationBarTitle("Navigation")
}
}
}
}
I was thinking more about how can i do this:我在想我该怎么做:
vc.modalPresentationStyle = .fullScreen
vc.modalTransitionStyle = .flipHorizontal
self.present(vc, animated: true, completion: nil)
but using SwiftUI.但使用 SwiftUI。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.