import React from "react";
import videojs from "video.js";
import "videojs-offset";
Results
Expected
The plugin should work ok.
Error output
TypeError: this.offset is not a function
Additional Information
Please include any additional information necessary here. Including the following:
versions
videojs
^7.3.0
I could make this work by registering the plugin manually:
import offset from "videojs-offset";
videojs.registerPlugin("offset", offset);
I've also tried to select a video.js version that corresponds with the one in videojs-offset package.json.
I think what happens is that the plugin is registered for its own version of video.js.
Description
When using imports, the plugin is not registered on video.js
Steps to reproduce
create-react-app
.video.js
andvideo.js-offsest
Results
Expected
The plugin should work ok.
Error output
TypeError: this.offset is not a function
Additional Information
Please include any additional information necessary here. Including the following:
versions
videojs
^7.3.0
I could make this work by registering the plugin manually:
I've also tried to select a video.js version that corresponds with the one in
videojs-offset
package.json. I think what happens is that the plugin is registered for its own version of video.js.