0

我遇到了问题,Vue js pusher 没有请求身份验证。没有错误没有警告甚至没有生成请求。

getPusherInstance() {
  let self = this

  return new Pusher(self.pusherKey, {
    authEndpoint: '/auth/video_chat',
    cluster: self.pusherCluster,
    auth: {
      headers: {
        'X-CSRF-TOKEN': document.head.querySelector('meta[name="csrf-token"]').content,
      }
    },
  });
}
4

0 回答 0