I have
$(window).on('online', function() { console.log('online'); });
And I'm trying to fire it on page load with
$(window).trigger('online');
Is there any way to do this without jquery? For example:
window.addEventListener('online', function() { console.log('online'); });
window.createEvent...?