docs: function (moduleName, ext, skipExt) {
                  var paths, syms, i, parentModule, url,
                      parentPath, bundleId,
                      pkgMain = getOwn(config.pkgs, moduleName);
  
                  if (pkgMain) {
                      moduleName = pkgMain;
                  }
  
                  bundleId = getOwn(bundlesMap, moduleName);
  
                  if (bundleId) {
                      return context.nameToUrl(bundleId, ext, skipExt);
                  }
  
                  //If a colon is in the URL, it indicates a protocol is used and it is just
                  //an URL to a file, or if it starts with a slash, contains a query arg (i.e. ?)
                  //or ends with .js, then assume the user meant to use an url and not a module id.
                  //The slash is important for protocol-less URLs as well as full paths.
                  if (req.jsExtRegExp.test(moduleName)) {
                      //Just a plain path, not module name lookup, so just return it.
                      //Add extension if it is included. This is a bit wonky, only non-.js things pass
                      //an extension, this method probably needs to be reworked.
                      url = moduleName + (ext || '');
                  } else {
                      //A module that needs to be converted to a path.
                      paths = config.paths;
  
                      syms = moduleName.split('/');
                      //For each module name segment, see if there is a path
                      //registered for it. Start with most specific name
                      //and work up from it.
                      for (i = syms.length; i > 0; i -= 1) {
                          parentModule = syms.slice(0, i).join('/');
  
                          parentPath = getOwn(paths, parentModule);
                          if (parentPath) {
                              //If an array, it means there are a few choices,
                              //Choose the one that is desired
                              if (isArray(parentPath)) {
                                  parentPath = parentPath[0];
                              }
                              syms.splice(0, i, parentPath);
                              break;
                          }
                      }
  
                      //Join the path parts together, then figure out if baseUrl is needed.
                      url = syms.join('/');
                      url += (ext || (/^data\:|\?/.test(url) || skipExt ? '' : '.js'));
                      url = (url.charAt(0) === '/' || url.match(/^[\w\+\.\-]+:/) ? '' : config.baseUrl) + url;
                  }
  
                  return config.urlArgs ? url +
                                          ((url.indexOf('?') === -1 ? '?' : '&') +
                                           config.urlArgs) : url;
              }