SP.Principal.loginName property (sp.js)

Gets the login name of the principal.

Applies to: apps for SharePoint | SharePoint Foundation 2013 | SharePoint Server 2013

var value = SP.Principal.get_loginName ()

Return value

Type: String

The login name of the principal.