Example of player integrating for Vue.js

  抱歉,这篇文章有英文版

Example of a simple Vue2 application that creates a player in the player container

<div id="player"><div/>
var app = new Vue({
   methods: {
      init: function () { 
         const script = document.createElement("script");
         script.async = true;
         script.src = "playerjs.js";
         document.head.appendChild(script);
      },
      playerjs: function () {
         let player = new Playerjs({id:"player", file:"https://plrjs.com/sample.mp4"});
      }
   },
   created: function () {
      this.init()
   }
});
function PlayerjsAsync(){
   app.playerjs();
}

You need to change the selected links to your own.


20.0.1
2024 © PlayerJS

登录

登录

免费注册

注册
注册即表示您同意服务条款
登录(如果您有帐户)

恢复密码

恢复
忘记电子邮件?联系我们