Search code examples
javascriptfirefox-addon-webextensionsbrowser-console

Access WebExtensions API from the Browser Console


Is it possible? I'd like to experiment with some functions in a REPL.


Solution

  • You can not do so from the Browser Console.

    However, you can if are debugging your WebExtension (accessed though about:debugging➞Debug) using the Add-on Debugger and your WebExtension has a background page (i.e. you have a defined a page or script in a background entry in your manifest.json):

    Using chrome APIs in Add-on Debugger