This repository has been archived by the owner on Feb 7, 2024. It is now read-only.
Replies: 1 comment 2 replies
-
You can set the host using Echo; it works even in React Native. I managed to make it work by passing the Pusher instance in the Echo config object. import Pusher from 'pusher-js'
import Echo from 'laravel-echo'
export default const EchoInstance = new Echo({
broadcaster: 'pusher',
Pusher,
// your configurations
wsHost: 'your-host.local',
wssHost: 'your-host.local',
wsPort: 6001, // default by laravel-websockets
wssPort: 6001,
key: 'your-env-key',
// ...
}) Then, you can use the instance to subscribe to your channel as you would normally. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi, does everyone can help me to implementation laravel websocket to react native?
the new SDK of Pusher for react native does not have option to set ws host.
please help me 🙏
Beta Was this translation helpful? Give feedback.
All reactions