https://hacks.mozilla.org/2013/05/optimizing-your-javascript-game-for-firefox-os/