Keeping these together for the sake of documentation, eventually these notes should be broken up into their own tickets. Consider this an incomplete list, but certainly a good starting point. 1. Primarly, there is a lot of duplicate code introduced in this changeset, most notably the script loading code which exists in two different files. 2. There are many places where call stacks can be reduced by eliminating the function expression wrappers that were introduced—these only serve to beef up the bytes over the wire and thicken call stacks and stack traces. If the goal was to improve performance by reducing property look ups, then a localized binding is sufficient. (showOverlay, hideOverlay, showStatus, hideSettings, toggleFavorite, etc.) 3. document.location is non-standard, use window.location 4. Standardize on either elem.classList or elem.className, using both creates readability, maintenance and refactoring hazards 5. The in operator is significantly less performant than doing an explicit, strict equality check against undefined http://jsperf.com/in-vs-explicit See also: https://groups.google.com/forum/?fromgroups=#!topic/mozilla.dev.gaia/bw_A1BXNkDU https://github.com/mozilla-b2g/gaia/pull/8038/files https://github.com/mozilla-b2g/gaia/commit/e6f1589e29a0b1163a42d14954f1df5f03291450
The Live connector code seems to avoid defining and using constructors https://github.com/mozilla-b2g/gaia/pull/8302/files#r3168709
Will, assign to myself to put this feedback in a wiki page.
Assignee: nobody → francisco
Firefox OS is not being worked on
Status: NEW → RESOLVED
Last Resolved: 9 months ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.