You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to use your plugin, via import statements. Problem is, that I can't get it working. I am getting error
Steps to reproduce
I have imported videojs and overlay plugin and try to register it, because when I didn't, I got error about function overlay to be undefined. Then I got error mentioned below
import videojs from 'video.js'
import overlay from 'videojs-overlay'
....
videojs.registerPlugin('overlay', overlay) // error
....
player.overlay({...})
Results
Expected
Expected to be working
Actual
Got error
Error output
VIDEOJS: ERROR: Error: Component Overlay does not exist
at Player.addChild (video.cjs.js:3361)
at videojs-overlay.es.js:371
at Array.map ()
at Player.plugin (videojs-overlay.es.js:347)
at Player.basicPluginWrapper [as overlay] (video.cjs.js:23094)
at videoTracking (application.js:130)
at Player. (application.js:92)
at HTMLDivElement.bound (video.cjs.js:2070)
at HTMLDivElement.data.dispatcher (video.cjs.js:1717)
at trigger (video.cjs.js:1849)
Additional Information
Please include any additional information necessary here. Including the following:
versions
videojs
"video.js": "^7.0.3",
"videojs-overlay": "^2.1.4"
browsers
Version 69.0.3497.100 (Official Build) (64-bit)
OSes
macOS High Sierra 10.13.6
plugins
"@dlive/videojs-resolution-switcher": "^0.6.0"
If I am doing something wrong, please help me and include it also in docs, because I haven't found any documentation about how to use your plugin with imports. Thanks
The text was updated successfully, but these errors were encountered:
There was problem with imports inside plugin. Overlay imported other videojs than I did in app.js, even if "name" is the same. Quick fix is to copy videojs-overlay.es.js to your lib and import it like: import '../lib/videojs-overlay'
You don't need to register plugin then.
Hope developers could find solution without this kinda forking
if you import the plugin you don't need to call registerPlugin; the registration will happen when the module is imported. you should be able to just call player.overlay after importing.
Description
I am trying to use your plugin, via import statements. Problem is, that I can't get it working. I am getting error
Steps to reproduce
I have imported videojs and overlay plugin and try to register it, because when I didn't, I got error about function overlay to be undefined. Then I got error mentioned below
import videojs from 'video.js'
import overlay from 'videojs-overlay'
....
videojs.registerPlugin('overlay', overlay) // error
....
player.overlay({...})
Results
Expected
Expected to be working
Actual
Got error
Error output
VIDEOJS: ERROR: Error: Component Overlay does not exist
at Player.addChild (video.cjs.js:3361)
at videojs-overlay.es.js:371
at Array.map ()
at Player.plugin (videojs-overlay.es.js:347)
at Player.basicPluginWrapper [as overlay] (video.cjs.js:23094)
at videoTracking (application.js:130)
at Player. (application.js:92)
at HTMLDivElement.bound (video.cjs.js:2070)
at HTMLDivElement.data.dispatcher (video.cjs.js:1717)
at trigger (video.cjs.js:1849)
Additional Information
Please include any additional information necessary here. Including the following:
versions
videojs
"video.js": "^7.0.3",
"videojs-overlay": "^2.1.4"
browsers
Version 69.0.3497.100 (Official Build) (64-bit)
OSes
macOS High Sierra 10.13.6
plugins
"@dlive/videojs-resolution-switcher": "^0.6.0"
If I am doing something wrong, please help me and include it also in docs, because I haven't found any documentation about how to use your plugin with imports. Thanks
The text was updated successfully, but these errors were encountered: