I'm setting up pusher-fake using the newest pusher client JS library (currently 7.0). After following the setup approach described in the documentation, I found that I wasn't able to connect to the pusher-fake server because the browser was trying to connect with TLS. After much debugging I found a workaround:
var pusher = <%= raw(PusherFake.javascript(forceTLS: false)) %>;
As of v6.0.0 (2020-04-27), pusher-js sets forceTLS to true by default which we need to override.
It seems like it may be a good idea to add the forceTLS: false setting to the config in PusherFake::Configuration#to_options. I think others will encounter this issue as more begin using later versions of pusher-js.
I'm setting up pusher-fake using the newest pusher client JS library (currently 7.0). After following the setup approach described in the documentation, I found that I wasn't able to connect to the pusher-fake server because the browser was trying to connect with TLS. After much debugging I found a workaround:
As of v6.0.0 (2020-04-27), pusher-js sets
forceTLS
totrue
by default which we need to override.It seems like it may be a good idea to add the
forceTLS: false
setting to the config inPusherFake::Configuration#to_options
. I think others will encounter this issue as more begin using later versions of pusher-js.