Redirect user to another page after API fetch and passing the results of the API fetch to that page
Unanswered
Munchkin posted this in #help-forum
MunchkinOP
Hi!
I am using next JS 13 as to build the front end for a flask app that responds to API calls.
One of the pages contains a survey that users fill in. The answers get passed with a POST request to the backend that returns a json with the interpretation.
I want to be able to redirect the user to a interpretation page that should receive the json.
How can I do that?
Thank you.
I am using next JS 13 as to build the front end for a flask app that responds to API calls.
One of the pages contains a survey that users fill in. The answers get passed with a POST request to the backend that returns a json with the interpretation.
I want to be able to redirect the user to a interpretation page that should receive the json.
How can I do that?
Thank you.
3 Replies
MunchkinOP
Any help appreciated
MunchkinOP
looks like useRouter and push is what i was looking for