Firefox features landing page should lazy-load images

RESOLVED FIXED

Status

RESOLVED FIXED
2 years ago
a year ago

People

(Reporter: agibson, Assigned: agibson)

Tracking

Production

Firefox Tracking Flags

(Not tracked)

Details

(URL)

Attachments

(1 attachment)

(Assignee)

Description

2 years ago
The new Firefox features landing page holds a collection of thumbnail images for each feature that gets promoted. This list will likely grow considerably, so it would be nice if the page had a method to lazy-load images as the user scrolls down the page. This will help improve page load time considerably as the content expands.

We'll likely need a placeholder image that gets shown until each thumbnail is lazy-loaded, and also some sort of fallback for no-JS users using <noscript>.
Probably with the Intersection Observer API? It will be enabled by default with Firefox 54 as per Bug 1362168.

https://developer.mozilla.org/en-US/docs/Web/API/Intersection_Observer_API
(Assignee)

Comment 2

2 years ago
(In reply to Kohei Yoshino [:kohei] from comment #1)
> Probably with the Intersection Observer API? It will be enabled by default
> with Firefox 54 as per Bug 1362168.
> 
> https://developer.mozilla.org/en-US/docs/Web/API/Intersection_Observer_API

I think we'd need something with a little broader cross-browser support for now.
(Assignee)

Comment 3

2 years ago
Hmm, although perhaps the polyfill there may prove robust enough, thanks Kohei will investigate :)
(Assignee)

Updated

2 years ago
Assignee: nobody → agibson
Status: NEW → ASSIGNED
(Assignee)

Comment 4

2 years ago
Created attachment 8871720 [details] [review]
GitHub pull request

Comment 5

a year ago
Commits pushed to master at https://github.com/mozilla/bedrock

https://github.com/mozilla/bedrock/commit/a3ef273c2eca6247b8340a1d1c3dd9d46c2918cd
[fix bug 1363304] Lazy load Firefox feature thumbnail images

https://github.com/mozilla/bedrock/commit/202f4728edc416975ac0572bfc02bcae73a242de
Merge pull request #4860 from alexgibson/bug-1363304-firefox-features-lazy-load

[fix bug 1363304] Lazy load Firefox feature thumbnail images

Updated

a year ago
Status: ASSIGNED → RESOLVED
Last Resolved: a year ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.