Skip to content

Optimize page speed #50

@johankj

Description

@johankj

The page load is getting quite big when viewing a page with a lot of videos on it. Sending all those requests and loading a bunch of iframes is probably unnecessary on first load, as most people probably won’t start watching 10 or 20 videos in one go.

A thumbnail url for videos on YouTube can be generated from the video id. Thumbnails for Vimeo videos can only be found by making a request to the Vimeo API.

I have a working implementation for lazy loading YouTube videos on the feature-lazy-load branch.
It could be extended to work with other video providers by having a thumbnail-attribute on each video. The build script (or another rake-command) could fetch and add all the missing thumbnails.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions