Closed Bug 985552 Opened 11 years ago Closed 10 years ago

add l10n.js to include.js bundle

Categories

(Marketplace Graveyard :: Consumer Pages, defect, P3)

defect

Tracking

(Not tracked)

RESOLVED FIXED
2015-03-24

People

(Reporter: mat, Assigned: kngo)

References

Details

(Keywords: perf, Whiteboard: [qa-])

We currently load l10n.js and include.js separately, making 2 HTTP requests instead of just one. We should add l10n.js to the include.js bundle to fix that.
Is this still a problem if we get SPDY on the CDN? This would perform better on SPDY wouldn't it?
SPDY would fix it but since we don't know when that'll happen it's probably best to tackle this now.
Assignee: nobody → mpillard
Well right now `include.js` is deferred in production, letting us load `l10n.js` and then the localisations before we load anything else in `include.js`. We'd have to maintain that order.
Ah, now I get it. That makes this bug pretty annoying to fix. I'll lower priority for now.
Priority: P2 → P3
No longer blocks: tarako-marketplace
Blocks: 992365
Assignee: mpillard → nobody
No longer blocks: 992365
Assignee: nobody → kngo
I can at least split it l10n.js into a global part and requirejs part so that duplicate code is not included twice.
Target Milestone: --- → 2015-03-17
Summary: Add l10n.js in include.js bundle → split l10n.js into the pre-include.js l10n initialization and the AMD l10n module
https://github.com/mozilla/marketplace-core-modules/pull/30 This improves things a bit by reducing the l10n.js size. For future reference, an idea might be to stop deferring include.js, remove the insertRequire from marketplace-gulp so it's not automatically run, and invoke our include.js bundle (with require) on onload for the locale JS script.
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Whiteboard: [qa-]
^ Assuming we stick l10n.js before include.js
Working on combining l10n.js and include.js into one bundle, while keeping the logic that we wait for l10n to initialize before we initialize the app.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Summary: split l10n.js into the pre-include.js l10n initialization and the AMD l10n module → add l10n.js to include.js bundle
Target Milestone: 2015-03-17 → 2015-03-24
You need to log in before you can comment on or make changes to this bug.