In my current project, I am working on an Express app and facing a challenge. I need to redirect after collecting data in a function, complete the redirect, return the data, and then resume from where I left off.
For instance:
> res.redirect('my/path' + someVariable);
> Traverse various routes and web pages to gather data
> Return to the point after the initial redirect with new data
> Perform checks with previous and new data before moving forward
Is this a common scenario? Are there straightforward ways to achieve this? Happy to provide further clarification if needed.
Thank you!