Explorar o código

注释掉XgVideoPlayer的插件动态导入

画安 hai 1 mes
pai
achega
5b0d2aa4f5
Modificáronse 1 ficheiros con 13 adicións e 13 borrados
  1. 13 13
      src/components/ui/XgVideoPlayer.vue

+ 13 - 13
src/components/ui/XgVideoPlayer.vue

@@ -94,19 +94,19 @@ export default {
             const plugins = [];
 
             // 按需动态导入格式插件(安装后才能使用)
-            try {
-                if (this.videoType === 'hls') {
-                    const HlsPlugin = require('xgplayer-hls').default;
-                    plugins.push(HlsPlugin);
-                }
-            } catch (e) { /* xgplayer-hls 未安装 */ }
-
-            try {
-                if (this.videoType === 'flv') {
-                    const FlvPlugin = require('xgplayer-flv').default;
-                    plugins.push(FlvPlugin);
-                }
-            } catch (e) { /* xgplayer-flv 未安装 */ }
+            // try {
+            //     if (this.videoType === 'hls') {
+            //         const HlsPlugin = require('xgplayer-hls').default;
+            //         plugins.push(HlsPlugin);
+            //     }
+            // } catch (e) { /* xgplayer-hls 未安装 */ }
+
+            // try {
+            //     if (this.videoType === 'flv') {
+            //         const FlvPlugin = require('xgplayer-flv').default;
+            //         plugins.push(FlvPlugin);
+            //     }
+            // } catch (e) { /* xgplayer-flv 未安装 */ }
 
             this.player = new Player({
                 el: this.$refs.container,