I have a Text view. Once this Text is pressed I need to navigate to another view of my application. I tried with the NavigationView and NavigationLink but I'm not able to perform the navigation.
HStack(alignment: .bottom, spacing: 0) {
Text("Already member? ")
.foregroundColor(.gray)
Text("Login now")
.foregroundColor(.blue)
.underline()
.onTapGesture {
// TODO: Navigate to LoginView()
}
}
.frame(minWidth: 0, maxWidth: .infinity, alignment: .center)
.padding(.top, 40)
This is my tappable Text. I don't know if the problem with the NavigationView depends on the multiple text that I have in my hstack.
