lib/web/urls.js
function resolveServer(path, options) {
    if (options === void 0) { options = {}; }
    var serverUrl = options.serverUrl || init.initOptions.serverUrl;
    if (path) {
        if (serverUrl) {
            path = url.resolve(serverUrl, path);
        }
    }
    else {
        path = serverUrl;
    }
    return url.resolve(path, '/');
}
function resolveServer(path, options) {
    if (options === void 0) { options = {}; }
    var serverUrl = options.serverUrl || init.initOptions.serverUrl;
    if (path) {
        if (serverUrl) {
            path = url.resolve(serverUrl, path);
        }
    }
    else {
        path = serverUrl;
    }
    return url.resolve(path, '/');
}
function resolveServer ( path , options ) { if ( options === void 0 ) { options = { } ; } var serverUrl = options . serverUrl || init . initOptions . serverUrl ; if ( path ) { if ( serverUrl ) { path = url . resolve ( serverUrl , path ) ; } } else { path = serverUrl ; } return url . resolve ( path , '/' ) ; }
computes a server url from a given path.

@param path path to resolve, relative or absolute.
@param options of server in effect.
@return {string} absolute URL of server.
computes a server url from a given path .