GO-Ve01
ServicesDevelopersBooksDictionaryPapersWikidataEncyclopediaSearchBabelCareersDeck

Search e01

One query across the encyclopedia, books, dictionary, papers, Wikidata and the developer library. Every hit carries its source.

6 results across 6 corpora for runtime.MessageSender.

Developer library 6

Internationalization

xtensionId</code> parameter to runtime.sendMessage(), and can't use it to check against the <code>id</code> property of a runtime.MessageSender object. </p> </td> </tr> <tr> <td><code>@@ui_locale</code></td> <td> The current locale; you might use this string to construct locale-specific URLs. </td> </tr> <tr> <td><code

Work with documentId

e document of the navigation target is known when the event fires). - Read the `documentId` from webRequest event details. - Read the `documentId` from runtime.MessageSender when receiving messages using runtime.onMessage, runtime.onConnect, and related listeners. - Read the `documentId` from the results of runtime.getContexts(). ## Using documentId to target documents When you have a `documentId`, you can use it t

extension.onRequestExternal

another extension. ## Syntax ```js-nolint chrome.extension.onRequestExternal.addListener(function( request, // optional any sender, // runtime.MessageSender sendResponse, // function ) { }) chrome.extension.onRequestExternal.removeListener(listener) chrome.extension.onRequestExternal.hasListener(listener) ``` Events have three functions: - `addListener(listener)` - : Adds a listener to this eve

extension.onRequest

or a content script. ## Syntax ```js-nolint chrome.extension.onRequest.addListener(function( request, // optional any sender, // runtime.MessageSender () => {/* … */} // function ) {/* … */}) chrome.extension.onRequest.removeListener(listener) chrome.extension.onRequest.hasListener(listener) ``` Events have three functions: - `addListener(listener)` - : Adds a listener to this event. - `

runtime

plications. ## Types - runtime.Port - : Represents one end of a connection between two specific contexts, which can be used to exchange messages. - runtime.MessageSender - : Contains information about the sender of a message or connection request. - runtime.PlatformOs - : Identifies the browser's operating system. - runtime.PlatformArch - : Identifies the browser's processor architecture. - runtime.Platform

runtime.onUserScriptMessage

urs. The function is passed these arguments: - `message` - : `object`. The message. This is a JSON-ifiable object. - `sender` - : A runtime.MessageSender object representing the sender of the message. - `sendResponse` - : A function to call, at most once, to send a response to the message. The function takes one argument, which is any JSON-ifiable object. This argument is passed back to

JSON results · Services directory