Hi! I’m trying to get some information from a POD but I’m having some problems with the asynchronous functions. I just want a method that receives an url and returns the text of the file that’s on that url. To do that I tried to use some parts of the code of the text editor from the React Generator:
Maybe the problem is that I don’t know how to return that text, but even If I just call another function or try to put that text on a global attribute to call it later, I receive a “Promise” object and I don’t know how to get the text from that object or how to wait until the text is ready (because the function is asynchronous, so I know I have to wait for the text).
Thank you in advance