Firefox 2.0 extension development

I wrote my first Firefox extension for version 0.9 in September of 2004. The development process was a huge pain in the ass, but I pressed on, powered by sheer delight that I could develop an interface within the Firefox chrome.

Two years and one point one version later, I’ve revisited Mozilla’s extension development docs, processes and community. What an improvement! You can actually make changes to your extension and see them without repackaging, uninstalling, restarting, reinstalling and restarting again! There’s a fabulous Extension Maker wizard that produces an extension skeleton starter file set, and batch scripts to do the packaging for you. It’s all very exciting. Here are some tools and reference links I used to update my extensions:

When I was done updating all my extensions, I got all uppity and submitted one to the Mozilla Add-ons directory. To my surprise and dismay/happiness, an editor tested it and rejected the submission because the extension threw a Javascript error! (An error that didn’t keep it from working, mind you, just cluttered up the Error Console.) I was pretty impressed with their vigilance (and sheepish about my shitty code), so I fixed it and re-submitted. It just got accepted.

Here’s a final list of my completed (and very simple) extensions, now compatible with Firefox 2.0:

I’ve got a few more extension ideas in the works, especially for web writers.

Notes on Mozilla Update: The great thing about hosting your extension there is that they take care of the auto-update on new versions, count your downloads for you, have per-extension comments enabled and are generally considered a trusted source for extensions (because they, you know, actually test them, as I found out). The bad part is that to host on Mozilla Update, you have to remove your custom auto-update URL from the install.rdf file. So, if you want to host your own extension (like say, to run ads on the page or include them in your custom portfolio) in addition to making it available on Mozilla Update, you have to build TWO separate versions - one, without an updateUrl set for Mozilla Update and one WITH an updateUrl for your own hosted version. That part kinda sucks.

Comments are closed.