The Video Js API – Referencing Video Objects

video js api
After using the excellent VideoJs HTML5 video player today, I thought a small article regarding improving site performance for video heavy websites was in order. The site in question is a project I inherited from a very large agency. The site was an internal application (so no need to worry about video SEO). By correctly referencing the VideoJS object through the Video Js API and displaying videos dynamically through JavaScript the site in question loaded faster and is more flexible for future updates.

The current site output the video HTML (36 video DOM elements nonetheless!) directly onto the webpage, as below. Dummy data has been used, a silly mammoth JavaScript closure and additional video setup options are omitted for the sake of brevity/sanity:
Continue reading The Video Js API – Referencing Video Objects