Properties

Link copied to clipboard

The clipboard read-only property of the Navigator interface returns a Clipboard object used to read and write the clipboard's contents. Available only in secure contexts.

Link copied to clipboard
Link copied to clipboard

The credentials read-only property of the Navigator interface returns the CredentialsContainer object associated with the current document, which exposes methods to request credentials. Available only in secure contexts.

Link copied to clipboard
Link copied to clipboard

The Navigator.geolocation read-only property returns a device.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

The login read-only property of the Navigator interface provides access to the browser's NavigatorLogin object, which a federated identity provider (IdP) can use to set its login status when a user signs into or out of the IdP. Available only in secure contexts.

Link copied to clipboard

The maxTouchPoints read-only property of the contact points that are supported by the current device.

Link copied to clipboard

The mediaCapabilities read-only property of the Navigator interface references a MediaCapabilities object that can expose information about the decoding and encoding capabilities for a given media format and output capabilities.

Link copied to clipboard

The mediaDevices read-only property of the Navigator interface returns a MediaDevices object, which provides access to connected media input devices like cameras and microphones, as well as screen sharing. Available only in secure contexts.

Link copied to clipboard

The mediaSession read-only property of the Navigator interface returns a MediaSession object that can be used to share with the browser metadata and other information about the current playback state of media being handled by a document.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

The permissions read-only property of the Navigator interface returns a status of APIs covered by the Permissions API.

Link copied to clipboard

The serviceWorker read-only property of the Navigator interface returns the ServiceWorkerContainer object for the associated document, which provides access to registration, removal, upgrade, and communication with the ServiceWorker. Available only in secure contexts.

Link copied to clipboard
Link copied to clipboard

The read-only userActivation property of the Navigator interface returns a UserActivation object which contains information about the current window's user activation state.

Link copied to clipboard
Link copied to clipboard

The wakeLock read-only property of the Navigator interface returns a WakeLock interface that allows a document to acquire a screen wake lock.

Link copied to clipboard

Functions

Link copied to clipboard
fun canShare(data: ShareData = definedExternally): Boolean

The canShare() method of the Navigator interface returns true if the equivalent call to navigator.share() would succeed. Available only in secure contexts.

Link copied to clipboard
abstract suspend fun clearAppBadge()
Link copied to clipboard
Link copied to clipboard

The Navigator.getGamepads() method returns an array of Elements in the array may be null if a gamepad disconnects during a session, so that the remaining gamepads retain the same index.

Link copied to clipboard
abstract fun registerProtocolHandler(scheme: String, url: String)

Available only in secure contexts.

abstract fun registerProtocolHandler(scheme: String, url: URL)
Link copied to clipboard
suspend fun requestMediaKeySystemAccess(    keySystem: String,     supportedConfigurations: ReadonlyArray<MediaKeySystemConfiguration>): MediaKeySystemAccess

The requestMediaKeySystemAccess() method of the Navigator interface returns a Promise which delivers a MediaKeySystemAccess object that can be used to access a particular media key system, which can in turn be used to create keys for decrypting a media stream. Available only in secure contexts.

Link copied to clipboard
Link copied to clipboard
suspend fun requestMIDIAccess(options: MIDIOptions = definedExternally): MIDIAccess

The requestMIDIAccess() method of the Navigator interface returns a Promise representing a request for access to MIDI devices on a user's system. Available only in secure contexts.

Link copied to clipboard
fun requestMIDIAccessAsync(options: MIDIOptions = definedExternally): Promise<MIDIAccess>
Link copied to clipboard
fun sendBeacon(url: String, data: BodyInit? = definedExternally): Boolean

The navigator.sendBeacon() method Asynchronous sends an HTTP POST request containing a small amount of data to a web server.

fun sendBeacon(url: URL, data: BodyInit? = definedExternally): Boolean
Link copied to clipboard
abstract suspend fun setAppBadge(contents: UInt53 = definedExternally)
Link copied to clipboard
abstract fun setAppBadgeAsync(contents: UInt53 = definedExternally): Promise<Void>
Link copied to clipboard
suspend fun share(data: ShareData = definedExternally)

The share() method of the Navigator interface invokes the native sharing mechanism of the device to share data such as text, URLs, or files. Available only in secure contexts.

Link copied to clipboard
fun shareAsync(data: ShareData = definedExternally): Promise<Void>
Link copied to clipboard

The vibrate() method of the Navigator interface pulses the vibration hardware on the device, if such hardware exists.