0

Digging on async / await notation in Javascript to make sure async code is finished before moving on to the next task.

The new problem I'm running into now is that now I'm waiting on the population of a whole lot of stuff on a page using bunches of:

element.innerHTML = data;

And near as I can tell, there is no way to know when element.innerHTML = data is complete as it doesn't return anything I can monitor / await for.

So, how do I know that the innerHTML has been populated successfully and can move on?

Trees4theForest
  • 1,267
  • 2
  • 18
  • 48
  • 1
    It is synchronous, so we're going to need to see an example of what you're trying to do and how it's not working to offer better advice. Ping me if you update your question and I'll reopen. – ceejayoz Mar 07 '18 at 23:41
  • @ceejayoz That's the bit of info I was looking for and couldn't find. Thanks for the lead! I'll dig back deeper to see where I'm going wrong. – Trees4theForest Mar 08 '18 at 00:04

0 Answers0