Implement SignalR integration and refactor WeatherPage

Added SignalR for real-time progress updates during weather data fetch. Refactored WeatherPage to use a new reusable WeatherGrid component and SignalRHelper. Improved loading UI with a radial progress indicator.
This commit is contained in:
2025-02-09 02:00:06 +01:00
parent 72b7902b55
commit c4071786ea
7 changed files with 184 additions and 65 deletions

View File

@@ -18,7 +18,7 @@ namespace Api.SignalR
logger.LogInformation("Background service sending message at: {Time}", DateTime.Now);
// Send a message to all connected clients.
await hubContext.Clients.User("user1234").SendAsync(
await hubContext.Clients.All.SendAsync(
"ReceiveMessage", // This is the client method name.
"Background Service", // Example sender.
$"Hello from the background task at {DateTime.Now:F}", // The message.