src/auth.js
function loginTo (endpoint, config) {
  return global.IS_BROWSER
    ? loginFromBrowser(endpoint, config)
    : loginFromNode(endpoint, config)
}
function loginTo (endpoint, config) {
  return global.IS_BROWSER
    ? loginFromBrowser(endpoint, config)
    : loginFromNode(endpoint, config)
}
function loginTo ( endpoint , config ) { return global . IS_BROWSER ? loginFromBrowser ( endpoint , config ) : loginFromNode ( endpoint , config ) }
Logs in to the specified endpoint with the given configuration
@param {AUTH_ENDPOINTS} endpoint - the endpoint type
@param {@link module:config-default} config - the config object
@returns {(Promise<String>|Promise<null>)} the WebID as a string if the
client cert is recognized, otherwise null.
Logs in to the specified endpoint with the given configuration