https://developer.mozilla.org/en-US/docs/Web/API/Network_Information_API
let preloadVideo = true;
var connection = navigator.connection || navigator.mozConnection || navigator.webkitConnection;
if (connection) {
if (connection.effectiveType=== 'cellular') {
preloadVideo = false;
}
Can you trust it?
Can you mis-use it?
You have to run JavaScript to use it, so you can't really use it before you're already loading resources.
What are the top use cases and best practices?