Button to another View

Hi, i have a problem. i coded a button, but now i want to make if the user clicks the button he will see another page, how can i do that?

PS: this is my piece of code  ` HStack() {         Button(action: {                   

// what do i have to putt here to perform the action?                    

       ` }, label: {
          Spacer()
          Text("I want chocolat!!!😱")
            .font(.largeTitle)
            .fontWeight(.heavy)
            .foregroundColor(Color.white)
            .multilineTextAlignment(.center)
            .lineLimit(2)
            .padding(.all, 50.0)
            .shadow(radius: /*@START_MENU_TOKEN@*/300/*@END_MENU_TOKEN@*/)
            .border(/*@START_MENU_TOKEN@*/Color.white/*@END_MENU_TOKEN@*/, width: /*@START_MENU_TOKEN@*/10/*@END_MENU_TOKEN@*/)
          Spacer()````

There are two main ways of showing a new view.

Using a NavigationLink to push to a new view:

NavigationView {
	NavigationLink(destination: NewView()) {
		Text("Show new view")
	}
} // make sure to embed in a NavigationView

Showing a sheet or full screen cover (slides up from the bottom) with the new view:

@State private var showingNewView = false

Button {
	showingNewView = true
} label: {
	Text("Show new view")
}
.sheet(isPresented: $showingNewView) {
	NewView()
}

Documentation links:

NavigationLink

Sheet

Full screen cover

Button to another View
 
 
Q