Blame view

node_modules/vue-video-player/src/index.js 737 Bytes
2a09d1a4   liuqimichale   添加宜春 天水 宣化
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
  
  /*
  * Vue-Video-Player ssr.js
  * Author: surmon@foxmail.com
  * Github: https://github.com/surmon-china/vue-video-player
  * Adapted from Videojs (https://github.com/videojs/video.js)
  */
  
  import _videojs from 'video.js'
  import videoPlayer from './player.vue'
  
  const videojs = window.videojs || _videojs
  const install = function (Vue, config) {
    if (config) {
      if (config.options) {
        videoPlayer.props.globalOptions.default = () => config.options
      }
      if (config.events) {
        videoPlayer.props.globalEvents.default = () => config.events
      }
    }
    Vue.component(videoPlayer.name, videoPlayer)
  }
  
  const VueVideoPlayer = { videojs, videoPlayer, install }
  
  export default VueVideoPlayer
  export { videojs, videoPlayer, install }