Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v-if not working with plyr. #514

Open
kenyonbowers opened this issue Feb 3, 2023 · 1 comment
Open

v-if not working with plyr. #514

kenyonbowers opened this issue Feb 3, 2023 · 1 comment

Comments

@kenyonbowers
Copy link

So, I have this code,
<vue-plyr v-if="devotionalVideoSrc && globalVideoState === VideoPlayerState.playing"> <video controls> <source size="1080" :src="devotionalVideoSrc" type="video/mp4" /> </video> </vue-plyr>
And I have a button that toggles the globalVideoState. When I click, and the globalVideoState is changed to VideoPlayerState.playing, it loads like it should. However, when I click it again two more times (so I toggle it to open again) it doesn't show. Idk what is going on.

@john-muinde
Copy link

I had the same issue. Wrap the vue-plyr with the vuejs template component and add the if to it.

Had the same issue but in my component I render youtube or other links dynamically

<vue-plyr ref="plyr" :options="plyrOptions" @ready="handlePlayerReady"
@playing="handlePlaying" @Pause="handlePause" @ended="handleEnded">







Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants