一、 video.js 视频播放
github:https://github.com/videojs/video.js
基础代码:
<script src="https://unpkg.com/video.js/dist/video.js"></script>
<video
id="my-player"
class="video-js vjs-default-skin vjs-big-play-centered"
controls
preload="auto" x5-playsinline="" playsinline="" webkit-playsinline="" poster=""
data-setup='{"example_option":true}'>
</video>
var player = videojs('my-player', options, function onPlayerReady() {
videojs.log('Your player is ready!');
// In this context, `this` is the player that was created by Video.js.
this.play();
// How about an event listener?
this.on('ended', function() {
videojs.log('Awww...over so soon?!');
});
});