stop playing video with js code example
Example: stop video javascript
<video id="video">
<source src="movie.mp4" type="video/mp4">
</video>
<script>
const video = document.querySelector("#video");
video.pause();
video.currentTime = 0;
</script>