Code Snippets – Get Your Code Snippets

If you’re new to Firefox extension or XULRunner programming, one of the first things you may want to do is find a good tutorial to help get a “hello world” project bootstrapped. Mozilla Developer Center (MDC) has more than a few to help you get started: Firefox Sidebar, Firefox Statusbar, XULRunner Application. We are working to get more on the way too.

The next thing you may need is small code snippets to help show you how to do common things. Things you probably already know how to do in another language or framework. You just need to know how to do it with XUL, JavaScript and XPCOM. You should definitely check out the Code Snippets section on the MDC. There is also an Example Code section on Mozillazine.

If there is something you want to know how to do, but it’s not on the MDC yet, let me know. Also, for any of you experienced Mozilla developers out there, go check out the code snippets and please add some of your own. Just keep the code snippet short and sweet, we’re not writing a full sample extension or application. If you do want to write a large sample extension or application, create a full blown tutorial.

2 Comments

  1. Greg K Nicholson said,

    December 12, 2006 @ 7:58 pm

    I’d like a toolbar button to flip an existing (hidden) pref; it’d appear pressed if the pref was true and unpressed otherwise.

  2. PJ Cabrera said,

    December 18, 2006 @ 8:36 pm

    Thanks, it’s awesome you’re providing all these resources in one place. Keep up the good work!

RSS feed for comments on this post