Iframe appears invisible

First, there’s no need to bump a thread that’s over a year old.

Secondly, rather than use that workaround to delay React attempting to render the better option would be to read introductory guides for React that show how to appropriately place scripts so that they don’t attempt to render before the DOM has finished loading. If you need to use a workout such as a setTimeout then that likely indicates you’ve placed your script in the wrong place.