liuyu 4 years ago
parent
commit
da9008322e
2 changed files with 5 additions and 0 deletions
  1. 1 0
      package.json
  2. 4 0
      src/views/live/roomDetail.vue

+ 1 - 0
package.json

@@ -19,6 +19,7 @@
     "stomp": "^0.1.1",
     "trtc-js-sdk": "^4.4.0",
     "vant": "^2.8.5",
+    "vconsole": "^3.3.4",
     "vue": "^2.6.11",
     "vue-meta": "^2.3.4",
     "vue-router": "^3.3.2",

+ 4 - 0
src/views/live/roomDetail.vue

@@ -154,6 +154,9 @@ import Vue from 'vue';
 import { Swipe, SwipeItem, Lazyload } from 'vant';
 import { Image as VanImage } from 'vant';
 import wx from 'weixin-js-sdk';
+import Vconsole from 'vconsole';
+let vConsole = new Vconsole();
+Vue.use(vConsole);
 Vue.use(Swipe);
 Vue.use(SwipeItem);
 Vue.use(VanImage);
@@ -665,6 +668,7 @@ export default {
           userId: _userid,
           userSig: res.data,
         });
+        console.log(this.client_);
         await this.client_.join({ roomId: this.roomname, role: 'anchor' });
         this.client_.on('stream-subscribed', event => {
           const remoteStream = event.stream;