code: function(workerModuleId) {
     var moduleRoot = uri.resolve(document.location.href, window.require.getModuleRoot());
     var initialScripts = [];
     Array.prototype.slice.apply(document.getElementsByTagName('script'), [0]).forEach(function(script) {
        if (script.src) {
           initialScripts.push(script.src);
        }
     });
  
     var URL = window.URL || window.webkitURL;
     var prefixString = workerPrefix.toString();
     // don't be afraid...
     prefixString = prefixString.substring(prefixString.indexOf("{") + 1, prefixString.lastIndexOf("}"));
     var blob = new Blob([
        'var __scripts = ["' + initialScripts.join('","') + '"];',
        prefixString,
        ';self.require.setModuleRoot("' + moduleRoot + '");',
        'self.require.run("'+ workerModuleId +'");'
     ], {type: 'application\/javascript'});
  
     var blobURL = URL.createObjectURL(blob);
     return new Worker(blobURL);
  }
docs: Setup a worker which has `require()` defined
  @ignore