You appear to be using server pre-render, but not persisting the pre-render state:
Blazor - Page Loads But Code Not Running Until SignalR Connection Opens
Elisheva
1
Reputation point
When my Blazor page starts up, you can see the page and type in the inputs. However, none of the event handlers get called. After about 2-3 seconds, all of the inputs get cleared and the event handlers start responding.
I think this is happening because the websocket connection wasn't ready when the page loaded.
Is there a way that I can set up the websocket connection earlier or prevent the page from displaying until the websocket connection is set up?