Why is this such a big deal?
Let’s suppose that your component lazily creates and caches a Storage connection, and some other code createInstance() your component everytime it needs to make an API call to it. This actually means the add-on will create a new connection each time, and this connection will survive till the component intended to kill it, that is usually on some profile shutdown notification, like profile-before-change. While this example is about Storage connections, any kind of resource may be easily leaked this way.
How to use it? XPCOMUtils supports some “magic” properties in the component, one of these is _xpcom_factory. From version 12, to make a singleton component, you can just: