Search code examples
firefox-addonfirefox-addon-sdk

Loading a webpage in the background using firefox-addon-sdk


I am new to creating add ons on firefox. Also a bit confused on which approach to take. I found 2 tutorials:

  1. https://developer.mozilla.org/en-US/docs/XUL/School_tutorial/Introduction?redirectlocale=en-US&redirectslug=XUL_School%2FIntroduction
  2. https://addons.mozilla.org/en-US/developers/docs/sdk/1.13/dev-guide/index.html

I want to load a webpage without showing it in another tab and do some parsing on it.. I found the 2nd link's tutorial easier to use and learn but I am not able to find the right apis for my task in that.


Solution

  • The SDK's page-worker module does exactly what you want:

    https://addons.mozilla.org/en-US/developers/docs/sdk/1.13/modules/sdk/page-worker.html