react-insta-stories
react-insta-stories copied to clipboard
Not start the story before content is loaded
Hi,
I am trying to show a video in the story, the video takes a second to load and the story timer starts before the video is loaded,
When trying to set isPaused to true it just ignores it and plays automatically,
How can I control the start and pause of the story? basically, I want to set the story to start when I have a ready event from my video component, my video content looks like that:
<div style={{ width: '100%', height: '100%' }}> <VideoJS options={options} onReady={handlePlayerReady} /> </div>
(I can't use the custom video you provide because I am streaming dash video and not mp4)
Thakns!
Hey @orizvida , isPaused
is a state variable, so setting it directly will not work. You'll have to use the action
prop instead as action('pause')
and action('play')
.