Chrome HTML5 Videos stop working if too many tabs are open - Memory issue?

后端 未结 4 1186
无人共我
无人共我 2021-01-05 08:39

I\'m using jQuery to dynamically write objects, and running videojs to init them. After I play a video, SOMETIMES when I try to play it again, it

4条回答
  •  天命终不由人
    2021-01-05 09:29

    Stu is correct. But sometimes, in my experience, Chrome ignores the preload="none" attribute and goes ahead and opens a connection anyway. I've had much problem with this when developing a site which had many smaller videos on it. The connections blocked the rest of the content (images, custom fonts (and when custom fonts are delayed, the text does not even render)) My solution was to build an own preloader which loads the images. This made sure I could control at least when the images (which was the most crucial aspect from a design point of view) was loaded.

    That solved the problem with images not showing but the problem still remained. So the best solution is to set up subdomains pointing to the same server, like: v1.server.com, v2.server.com, and so on. This means you won't have to move your files and you get the benefit from enabling browsers to have more open connections. Watch out for increased dns lookup time though.

提交回复
热议问题