Bug 941969 - Optimize JS for system app

https://bugzilla.mozilla.org/show_bug.cgi?id=941969