krot

jitsi

Oct 27th, 2021
829
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  head() {
  2.       return {
  3.         title: this.title,
  4.  
  5.            script: [
  6.             {
  7.               src: "https://meet.jit.si/libs/lib-jitsi-meet.min.js",
  8.               type: "text/javascript"
  9.             },
  10.            
  11.           ]
  12.  
  13.            
  14.       }
  15.  jitsiInit(){
  16.         if(!window)return;
  17.  
  18.        JitsiMeetJS.init();
  19.         const options = {
  20.               hosts: {
  21.                   domain: 'c..net',
  22.                 //  muc: 'conference.c..net'
  23.               },
  24.               bosh: 'https://c..net/http-bind'
  25.           };
  26.        var connection = new JitsiMeetJS.JitsiConnection(null, null, options);
  27.  
  28.           connection.addEventListener(JitsiMeetJS.events.connection.CONNECTION_ESTABLISHED, function(){console.info('onConnectionSuccess');});
  29.           connection.addEventListener(JitsiMeetJS.events.connection.CONNECTION_FAILED,function(){console.info('onConnectionFailed');});
  30.           connection.addEventListener(JitsiMeetJS.events.connection.CONNECTION_DISCONNECTED, function(){console.info('disconnect');});
  31.  
  32.  
  33.           JitsiMeetJS.mediaDevices.addEventListener(
  34.     JitsiMeetJS.events.mediaDevices.DEVICE_LIST_CHANGED,
  35.     function(){console.info('onDeviceListChanged');});
  36.  
  37.           connection.connect();
  38.  
  39.         console.info('jipa',connection);
RAW Paste Data