Skip to content

Conversation

@bz2
Copy link

@bz2 bz2 commented Oct 25, 2018

Currently when using the preload=none property on a video as a hint
to avoid loading video contents on page load, the overlay is always
a progress spinner. With this change play is shown instead.

Also add tests for existing UA logic around loading status.

Fixes: #132

Currently when using the preload=none property on a video as a hint to avoid loading video contents on page load, the overlay is always a progress spinner. With this change play is shown instead. Also add tests for existing UA logic around loading status. Fixes: #132
};

function isLoading(readyState, networkState, userAgent) {
if (readyState == 0 && networkState == 1) {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use strict equality operator ===

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the review!

Yes, this could use === though the eslint config of this project doesn't include the eqeqeq rule stating it must, and in practice callers are using the browser enums not null or other complicating values.

This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants