Elmish.Bridge icon indicating copy to clipboard operation
Elmish.Bridge copied to clipboard

Q: SignalR for automatic fallback?

Open zakaluka opened this issue 6 years ago • 4 comments

Hi @Nhowka,

I have a question on fallbacks. Is there a plan to use / upgrade to https://github.com/aspnet/SignalR so that Elmish.Bridge can take advantage of automatic fallbacks? According to https://docs.microsoft.com/en-us/aspnet/core/fundamentals/websockets?view=aspnetcore-2.1, using Microsoft.AspNetCore.WebSockets requires the developer (aka either you or the app developer) to implement fallback to alternative transport protocols.

Would love to hear your thoughts on this.

Thank you

zakaluka avatar Jun 26 '18 15:06 zakaluka

Good thinking! I'll check the impact on bundle size if any and if I can keep the ServerHub as it is or give some access to SignalR Hub.

Nhowka avatar Jun 26 '18 16:06 Nhowka

I'm not sure if it will be needed... Looks like there is good support for it: https://caniuse.com/#feat=websockets

As Elmish doesn't do much with javascript disabled, maybe it will be unnecessary complexity.

Nhowka avatar Jul 26 '18 03:07 Nhowka

For us the issue is not the browsers themselves, but rather intercepting proxies / firewalls, which are unfortunately common in corporate environments.

Have you already taken a look at how much effort it would be to model Elmish.Bridge on top of SignalR, or whether the SignalR communication layer can be extracted out?

0x53A avatar Aug 28 '18 13:08 0x53A

That's fair. Now that there's a possibility of having more options, I'll do it as a choice and if it works well I'll make it the default. I hope I can work on it soon.

Nhowka avatar Aug 28 '18 13:08 Nhowka