Answer the question
In order to leave comments, you need to log in
How to call a function only after the external strip is fully loaded?
I have a react app.
There is a script that, after loading and executing, adds the window.anyFunc function.
How to track that the script has already loaded?
That is, when window.anyFunc exists, call it, passing values to it with redux.
The problem is that I call a function in the componentDidMount of the main application component, but at that moment the script may not yet be loaded and called.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question