.Net core razor pages (MVC) SignalR client error message "connection disconnected with error 'websocket is not in the Open state'" handling.
Placing SignalR client side code outside the @section Scripts {} can resolve 'websocket is not in the Open state' error.
The recommended approach is to place JavaScript code in the <head> or end of <body> section to avoid interference with other scripts.