acquire.js
function(source, callback) {
        callback = callback || noop;

        //if there's a queue
        if (queue[source] instanceof Array) {
            //just add it
            return queue[source].push(callback);
        }

        //otherwise there is not a queue
        //so let's create one
        queue[source] = [callback];

        var script = document.createElement('script');
        var head = document.getElementsByTagName('head')[0];

        script.async = 1;

        head.appendChild(script);

        script.onload = script.onreadystatechange = function( _, isAbort ) {
            if(isAbort || !script.readyState || /loaded|complete/.test(script.readyState) ) {
                script.onload = script.onreadystatechange = null;
                script = undefined;

                if(!isAbort) {
                    queue[source].forEach(function(callback) {
                        callback();
                    });

                    delete queue[source];
                }
            }
        };

        script.src = source;
    }
function(source, callback) {
        callback = callback || noop;

        //if there's a queue
        if (queue[source] instanceof Array) {
            //just add it
            return queue[source].push(callback);
        }

        //otherwise there is not a queue
        //so let's create one
        queue[source] = [callback];

        var script = document.createElement('script');
        var head = document.getElementsByTagName('head')[0];

        script.async = 1;

        head.appendChild(script);

        script.onload = script.onreadystatechange = function( _, isAbort ) {
            if(isAbort || !script.readyState || /loaded|complete/.test(script.readyState) ) {
                script.onload = script.onreadystatechange = null;
                script = undefined;

                if(!isAbort) {
                    queue[source].forEach(function(callback) {
                        callback();
                    });

                    delete queue[source];
                }
            }
        };

        script.src = source;
    }
function ( source , callback ) { callback = callback || noop ; //if there's a queue if ( queue [ source ] instanceof Array ) { //just add it return queue [ source ] . push ( callback ) ; } //otherwise there is not a queue //so let's create one queue [ source ] = [ callback ] ; var script = document . createElement ( 'script' ) ; var head = document . getElementsByTagName ( 'head' ) [ 0 ] ; script . async = 1 ; head . appendChild ( script ) ; script . onload = script . onreadystatechange = function ( _ , isAbort ) { if ( isAbort || ! script . readyState || / loaded|complete / . test ( script . readyState ) ) { script . onload = script . onreadystatechange = null ; script = undefined ; if ( ! isAbort ) { queue [ source ] . forEach ( function ( callback ) { callback ( ) ; } ) ; delete queue [ source ] ; } } } ; script . src = source ; }
Gets a script remotely, runs it
and caches it.

@param string
@param function
@return void
Gets a script remotely runs it and caches it .