MDN self-hosted library · e01.org

userScripts.getScripts()

Returns user scripts registered by the extension.

no runnable cells webextension-api-function upstream source

Returns user scripts registered by the extension.

Syntax

const gettingUserScripts = await browser.userScripts.getScripts(
  filter       // object
);

Parameters

  • filter
  • : userScripts.UserScriptFilter. A list of user script IDs to return.

Return value

A Promise fulfilled with an array of userScripts.RegisteredUserScript objects. If no matching user scripts are found, the array is empty. If the request fails, the promise is rejected with an error message.

h2

Browser compatibility