Skip to content

Is it possible to get Realtime events using Blazor standalone web assembly? #181

Closed Answered by s3312345
s3312345 asked this question in Q&A
Discussion options

You must be logged in to vote

Did some digging and worked out the problem myself.

Looks like the latest build of RealTime is broken for client side execution due to this change: https://github.com/supabase-community/realtime-csharp/blame/master/Realtime/RealtimeSocket.cs#L93

The underlying problem is that SetRequestHeader has been marked as not supporting browser side execution:
https://github.com/dotnet/runtime/blob/1d1bf92fcf43aa6981804dc53c5174445069c9e4/src/libraries/System.Net.WebSockets.Client/src/System/Net/WebSockets/ClientWebSocketOptions.cs#L76C13-L80C10

The only work around for now is to downgrade back down to v1.1.0 avoiding v1.1.1

Hope it helps someone in the future.

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by s3312345
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants