A few questions about hls video example! #658
Replies: 1 comment 1 reply
-
Here is a sample code I tried to reproduce then pen about the integration of Plyr and hls.js. you need to setup the const video = document.getElementById("plyr") as HTMLVideoElement;
// ...
plyr.setup(video); There is a reference of ref.current!.plyr.media = video Why did you did such a thingThe Idea of So we didn't install and use plyr as dependencies but as a peer dependency. Try to make the package as coupled as possible. Read more about the mindset of Is this the perfect wayI doubt to say that this is perfect, but we are going toward perfection, feel free to join our mindset of making react-forwardable components. There are lots of things you can do, trust in yourself
|
Beta Was this translation helpful? Give feedback.
-
Hi, I was reading your Hls video example. I have a question about a line code this
ref.current!.plyr.media = video
. What do you do at this line?@gamestap99
Beta Was this translation helpful? Give feedback.
All reactions