0

Is it somehow possible to display a status message while fetching a database request from some API with Node.js and Express.js? The db request is taking some minutes... I'd like to display a status message like "pending request.." in the browser as long as it takes to get the results.. is that possible in some way? I know the request either is completed or failed, and I would probably need some state object or some kind of callback in the browser to do that, but I have no idea how..

MMMM
  • 3,320
  • 8
  • 43
  • 80
  • Display pending message, start request, wait for response, display error or success message based on response. Have you tried anything? There is nothing conceptually difficult about this. – Azami Feb 11 '19 at 14:36
  • Could you add some basic examples of your code in the question? It's hard to tell what specific part you are confused about. – Treble Snake Feb 11 '19 at 14:48

0 Answers0