0

With reference to MDN, async :- Set this Boolean attribute to indicate that the browser should, if possible, execute the script asynchronously. It has no effect on inline scripts (i.e., scripts that don't have the src attribute).

the issue i am facing is that, i want to call a method as soon as the corresponding js file loaded using async. How to detect whether the fill is loaded or not.

atul
  • 552
  • 4
  • 16
  • 2
    If you need to specifically run something, or load something, after a script has loaded, you probably shouldn't be using the `async` attribute ? Anyway, the script tag still has an `onload` event. – adeneo Jul 25 '16 at 18:44
  • Possible duplicate of [How may I reference the script tag that loaded the currently-executing script?](http://stackoverflow.com/questions/403967/how-may-i-reference-the-script-tag-that-loaded-the-currently-executing-script) – Jim Jul 25 '16 at 19:44

0 Answers0