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

Video Does not cancel downloading when you use it in a component like a modal. #120

Open
rezaser74 opened this issue Dec 30, 2024 · 1 comment

Comments

@rezaser74
Copy link

No description provided.

@rezaser74
Copy link
Author

Hello, I hope you doing well.

I had a problem with the video component, where you need to use the library into a modal and close it,
when closing the component it's still running requests and trying to download the video because it has not abort controller in requests.
I fixed this problem with a ref and changed video tag events.

i wrote a function to empty src on the video tag, pause it & reload it,
it's going to reset the video and cancel all requests from the video tag.
it will be a good idea if requests cancel while closing.

close() { // handle the video tag inside the library for prevent download const videoElement = this.$refs.videoplayer.$el.querySelector('video') videoElement.pause() videoElement.src = '' videoElement.load() },

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

1 participant