
var player = videojs('my-video', vhs: // Enable CORS credentials withCredentials: true, // Allow redirects for manifests and segments handleManifestRedirects: true, // Use native HLS on Safari (true) or force VHS (false) overrideNative: false, // Limit the buffer ahead to reduce memory usage maxBufferLength: 30, // Maximum time allowed for seeking seekTo: 10
VIDEOJS: WARN: player.hls is deprecated. Use player.tech. ... - GitHub
Unlike the old HLS tech, VHS supports both HLS and DASH streams.
To understand this transition, it helps to look at the history of adaptive bitrate streaming in Video.js.
: By renaming the internal property from hls to vhs , the developers avoided confusion when using the same engine to play DASH content. How to Fix the Warning
// package.json
If you are manually accessing the streaming tech object to check playlists or bandwidth, change your syntax: javascript
The warning is harmless in the short term, but you should update your code to avoid breakage when upgrading Video.js beyond version 7 or 8 (depending on your exact setup).
If you need to access live streaming properties like playlists or bandwidth, use the property on the tech Bandwidth: player.tech().vhs.bandwidth Current Playlist: player.tech().vhs.playlists.media() Representations: player.tech().vhs.representations() 3. Handling Quality Levels If you are using the Quality Levels plugin to build a quality picker, ensure you are referencing the tech for any manual overrides ⚠️ Important Considerations videojs-http-streaming (VHS) - GitHub 22 Jul 2025 —
Video.js eventually integrated streaming capabilities directly into the core library.
After changing tech_.hls to tech_.vhs :
Resolving this warning requires updating your CSS, JavaScript, or plugin configuration depending on where the deprecated string is being called. 1. Update CSS Selectors