userScripts.RegisteredUserScript

A RegisteredUserScript object is returned by a call to userScripts.register() and represents the user scripts registered in that call.

The object defines a single method, unregister(), which is used to unregister the user scripts.

Note: If this object is destroyed (for example because it goes out of scope) then the associated scripts will be unregistered automatically, so you should keep a reference to this object for as long as you want the user scripts to stay registered.

Methods

unregister()
Unregisters the user scripts represented by this object.

Browser compatibility

Update compatibility data on GitHub
DesktopMobile
ChromeEdgeFirefoxOperaSafariFirefox for Android
RegisteredUserScriptChrome No support NoEdge No support NoFirefox Full support 68
Full support 68
Full support 66
Disabled
Disabled From version 66: this feature is behind the extensions.webextensions.userScripts.enabled preference (needs to be set to true). To change preferences in Firefox, visit about:config.
Opera No support NoSafari No support NoFirefox Android Full support 68
unregisterChrome No support NoEdge No support NoFirefox Full support 68
Full support 68
Full support 66
Disabled
Disabled From version 66: this feature is behind the extensions.webextensions.userScripts.enabled preference (needs to be set to true). To change preferences in Firefox, visit about:config.
Opera No support NoSafari No support NoFirefox Android Full support 68

Legend

Full support  
Full support
No support  
No support
User must explicitly enable this feature.
User must explicitly enable this feature.