videojs / videojs-contrib-quality-levels

Other
154 stars 52 forks source link

"TypeError: this.player.qualityLevels is not a function" #124

Closed thinhnguyen1105 closed 2 years ago

thinhnguyen1105 commented 3 years ago

Description

catch error player.qualityLevels is not a function

I'm using Vuejs and implement video.js for play video hls. I want to change quality of hls video and installed videojs-contrib-quality-levels but still not working. ( Video.js version 7.11.5 has been stabled in my system so i don't want to change version of videoJS ). Any solution? Thanks so much

Environment

"vue": "^2.6.11" "video.js": "7.11.5" "videojs-contrib-quality-levels": "^2.0.9",

image

thinhnguyen1105 commented 3 years ago

image

gkatsev commented 3 years ago

Has the only change you've made to update to Video.js 7.11? We got a similar report here https://github.com/videojs/video.js/issues/7091

yougotwill commented 3 years ago

If anyone else has this issue. Might be really obvious but make sure to directly import the package wherever you are using it. i.e. import "videojs-contrib-quality-levels";.

beedrill commented 2 years ago

If anyone else has this issue. Might be really obvious but make sure to directly import the package wherever you are using it. i.e. import "videojs-contrib-quality-levels";.

Thanks a lot, that works! Can't believe they didn't include this step in the document...