Questions tagged [pusher-js]

The javascript client library of Pusher

The repository of pusher-js can be found here: https://github.com/pusher/pusher-js

201 questions
2
votes
2 answers

Pusher with Vue and Laravel API not working

I am using Vue SPA and Laravel. I have google it for hours and tried many things but I can't find a way to make it work. In index.html I have This is my subscribe method: subscribe() { let…
Roland
  • 24,554
  • 4
  • 99
  • 97
2
votes
1 answer

How do I get Laravel Echo to work on production?

I'm having trouble with Laravel Echo (I think). I've built a vue chat app that works locally. I've even cloned it onto another machine and got it working fine. But when I get it onto production, it's not working. I'm not running npm on the server,…
ajw4sk
  • 95
  • 2
  • 13
1
vote
0 answers

Laravel Echo + pusher, stop trying to connect to server if server is not available

How to stop trying to create a connection when getting a server connection fail? const echo = new Echo({ broadcaster: 'pusher', key: process.env.MIX_PUSHER_APP_KEY, cluster: process.env.MIX_PUSHER_APP_CLUSTER, wssHost:…
Sanya H
  • 213
  • 3
  • 7
1
vote
0 answers

401 (Unauthorised) response from Pusher due to failed authentication with Sanctum

Getting a 401 (Unauthorised) response from Pusher due to failed authentication using Laravel Sanctum. [Error] Pusher : : ["Error: Unable to retrieve auth string from channel-authorization endpoint - received status: 401 from…
Richard
  • 422
  • 7
  • 17
1
vote
1 answer

App showing white blank screen when quitting app with back button after open push notification

After launching app from tapping on push notification, app is showing white blank screen when quit app with hardware back button. Logged react navigation stack but showing only 1 route in the stack. I've tried to override the back function by using…
Annie Tan
  • 259
  • 4
  • 14
1
vote
1 answer

Laravel websockets with nginx

I have followed tutorials to configure laravel with websockets using docker, except that my php version is PHP 8.1.9, and laravel 8. My nginx container is a reverse proxy to web_dev container, and does SSL termination. So further communication…
Daniel Katz
  • 2,271
  • 3
  • 25
  • 27
1
vote
0 answers

Laravel Echo automatically disconnects first connected user

I'm building a real-time chat using Laravel, Ably (Pusher) and Vue 3 and a presence channel. Everything works great, but for some reason the first connected client gets disconnected automatically after ~10 seconds (the leaving event occurs for that…
1
vote
1 answer

pusher-websocket-react-native returns 403 on private channels

I am building a react native application with laravel api, and pusherjs websocket. But i am getting the 403 error on private channel. I am quite familiar with the Pusher.js for web, and i know that when it throws this error, its an authentication…
Nathaniel
  • 53
  • 1
  • 5
1
vote
1 answer

react native laravel echo: can not find variable pusher

i have imported laravel-echo and @pusher/pusher-websocket-react-native in react native but error occur:can not find variable pusher please tell me solution will be thankfully import Echo from "laravel-echo"; import { Pusher, PusherMember, …
1
vote
1 answer

Issues With Pusher-js client in vue

I am using vue 3 to build a realtime chat app. I am also using laravel-echo@^1.10.0 and pusher-js@^7.0.3. In the main.js I instantiated the laravel-echo and passed in the credential from the .env file const app =…
NwaiwuIsidore
  • 519
  • 1
  • 6
  • 12
1
vote
1 answer

Pusher trigger() method is giving error 500

So I was building chat functionality in laravel for a website using Pusher , everything was working fine till yesterday. But when I run the chat module again, I found out that trigger() method is giving error (Internal server error). ` use…
pyrogrammer
  • 560
  • 3
  • 17
1
vote
1 answer

How to pass pusher to utility classes in node.js

I am using Node.js here with Pusher, but it's not a pusher related question, it's more of a Node.js question. In Server.js (declare pusher, and used pusher once for authentication) import express from 'express'; import cors from 'cors'; import…
william007
  • 17,375
  • 25
  • 118
  • 194
1
vote
0 answers

Redux toolkit state not getting updated data when call in pusher

I am using redux toolkit to update my real time messages but in pusher bind function the redux state is not getting the updated data. const messages = useSelector((state) => state.messages.chatMessages); const chatId = useSelector((state) =>…
S.Hashmi
  • 485
  • 1
  • 8
  • 29
1
vote
1 answer

laravel echo wont subscribe to private channel even the user is authenticated

I'm using Laravel: 8.54 Laravel Sanctum: 2.11 Pusher Php Server: 7.0 NuxtJs: 2.15.7 pusher-js: 7.0.4 laravel-echo: 1.11.3 Event Class
1
vote
0 answers

Vue3 laravel-echo with pusher-js not triggering events

I am trying to iplement websocket using VUE3 + LARAVEL-ECHO + PUSHER-JS