> Hi there
> a dummy question for rare who still develop Tb extension.
> How to easily reload extension once modified ?
> During development process, it is necessary to uninstall/install extension a huge number of times. Any other method ?
Indeed, what I want is to *not* restart neither Tb nor reload the addon during development process. I don't know if there is a better way through online debugger or something else, anyway I setup a skeleton addon that loads modules each time that it is enabled.
See explanation below.
This is a skeleton to ease the development process of add-on:
no more need to uninstall/install new version at each new version, only unactivate/activate (i.e. 2 clicks rather than uninstall/file chooser/wait for installation)
The bootstrap (re)loads the module.js at each startup.
To do that you need :
1) Create a bootstrap.js (this file) that loads (mozIJSSubScriptLoader object) the module that you want to develop (create at least an empty file)
2) Add to your chrome.manifest the declaration of location of your modules, for example :
resource mymodules mymodules/
to access files located under <addon_directory_installation>/mymodules/ with "resource://mymodules/" URL
3) Set <em:unpack>true</em:unpack> option in install.rdf file
4) Install and activate your addon
5) Access to <your_profile_directory>/extensions/<addon_name>/modules/ and edit your module.js file
6) To get changes taken into account, simply unactivate/activate the addon.