Skip to content

Firefox fails to fire progress event without preload attribute #150

@bekriebel

Description

@bekriebel

For some video files (seems to primarily happen on MPEG 4 Type 2 files), the Progress event does not fire for a loaded resource on Firefox 74. This seems to be caused when not enough of the partial content range has been loaded by the browser's default preload value on a media element.

Since the loader should be requesting that the resource be loaded fully, the preload attribute should be set to auto.

For the 3.x branch, I tested this by adding this.data.preload = 'auto'; right before this.data.load(); here: https://github.com/englercj/resource-loader/blob/release/3.x/src/Resource.js#L636. However, this should probably be wrapped in an if statement to only add preload to a video type element.

You can see that a video is not being preloaded with any video file by watching the network traffic and seeing that only the first bits of the file are downloaded. This doesn't seem to cause the progress event failure for all videos, though. I can link to a video that causes the progress issue reliably in a private message, or I can try to find or create a free video that causes the issue if needed.

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