Location
interface
interface LocationThe location (URL) of the object it is linked to. Changes done on it are
reflected on the object it relates to. Accessible via
globalThis.location.
variable
var Location: { … }The location (URL) of the object it is linked to. Changes done on it are
reflected on the object it relates to. Accessible via
globalThis.location.
Constructors
constructor
new Location(): neverProperties
ancestorOrigins
readonly ancestorOrigins: DOMStringListReturns a DOMStringList object listing the origins of the ancestor browsing contexts, from the parent browsing context to the top-level browsing context.
Always empty in Ende.
hash
hash: stringReturns the Location object's URL's fragment (includes leading "#" if non-empty).
Cannot be set in Ende.
host
host: stringReturns the Location object's URL's host and port (if different from the default port for the scheme).
Cannot be set in Ende.
hostname
hostname: stringReturns the Location object's URL's host.
Cannot be set in Ende.
href
href: stringReturns the Location object's URL.
Cannot be set in Ende.
origin
readonly origin: stringReturns the Location object's URL's origin.
pathname
pathname: stringReturns the Location object's URL's path.
Cannot be set in Ende.
port
port: stringReturns the Location object's URL's port.
Cannot be set in Ende.
protocol
protocol: stringReturns the Location object's URL's scheme.
Cannot be set in Ende.
search
search: stringReturns the Location object's URL's query (includes leading "?" if non-empty).
Cannot be set in Ende.
prototype
readonly prototype: LocationMethods
toString
toString(): stringassign
assign(url: string): voidNavigates to the given URL.
Cannot be set in Ende.
reload
reload(): voidReloads the current page.
Disabled in Ende.
reload(forcedReload: boolean): voidDeprecated.
replace
replace(url: string): voidRemoves the current page from the session history and navigates to the given URL.
Disabled in Ende.
location
variable
var location: LocationThe Location object describing the absolute URL of the main
module, available when the program is started with the --location flag.
Accessing it without --location throws.