let’s say there is a Node js Server for prime number, it serves to web page one for user input and the other for result
When 1st user demands the nth prime number on the first page, prime number calculation is written in the async-await pattern. Still, the code is executed on the main thread, so while prime number execution is ongoing, that time 2nd user demands the first web page.
Is there a way to push the prime number function with its memory state, serve the page to the second user and then resume the function
2