headjs/headjs — Issue #165: load.js component: head.js method might not call the callback function when the isAsync flag is true (chrome 14)
Author: theosp
Created: 2011-10-17 15:07:19+00:00
State: open

The head.js() method has two versions, one for browsers for which the isAsync variable is true and one for the others.

ASFAIK, since chrome 14 (maybe 13?) its value is true. (since doc.createElement("script").async === true returns true).

I have found a serious problem with the isAsync version of the method, causing it to never call the callback function if the last script passed to it doesn't load last.