|
| 1 | +## About |
| 2 | + |
| 3 | +`Microsoft.AspNetCore.SignalR.Client.Core` provides core functionality for the .NET client for ASP.NET Core SignalR. |
| 4 | + |
| 5 | +> [!NOTE] |
| 6 | +> This package contains only the connection-agnostic components of the .NET SignalR client, and does not provide a default connection implementation. In most scenarios, the [`Microsoft.AspNetCore.SignalR.Client`](https://www.nuget.org/packages/Microsoft.AspNetCore.SignalR.Client) package should be used because it provides an HTTP connection implementation. |
| 7 | +
|
| 8 | +## Key Features |
| 9 | + |
| 10 | +SignalR provides the following capabilities: |
| 11 | +* Automatic connection management |
| 12 | +* Sending messages to all connected clients simultaneously |
| 13 | +* Sending messages to specific clients or groups of clients |
| 14 | +* Scaling to handle increasing traffic |
| 15 | + |
| 16 | +## How to Use |
| 17 | + |
| 18 | +To use `Microsoft.AspNetCore.SignalR.Client.Core`, follow these steps: |
| 19 | + |
| 20 | +### Installation |
| 21 | + |
| 22 | +```shell |
| 23 | +dotnet add package Microsoft.AspNetCore.SignalR.Client.Core |
| 24 | +``` |
| 25 | + |
| 26 | +### Configuration |
| 27 | + |
| 28 | +The .NET SignalR client requires a connection implementation. To use an HTTP connection implementation, install the [`Microsoft.AspNetCore.SignalR.Client`](https://www.nuget.org/packages/Microsoft.AspNetCore.SignalR.Client) package. |
| 29 | + |
| 30 | +## Main Types |
| 31 | + |
| 32 | +The main types provided by `Microsoft.AspNetCore.SignalR.Client.Core` include: |
| 33 | +* `HubConnectionBuilder`: Provides an abstraction to construct new SignalR hub connections |
| 34 | +* `HubConnection`: Defines methods for managing a hub connection, including: |
| 35 | + * Starting and stopping the connection |
| 36 | + * Sending and receiving messages |
| 37 | + * Handling disconnects and attempting reconnects |
| 38 | +* `HubConnectionOptions`: Provides options for configuring a `HubConnection` |
| 39 | + |
| 40 | +## Additional Documentation |
| 41 | + |
| 42 | +For additional documentation and examples, refer to the [official documentation](https://learn.microsoft.com/aspnet/core/signalr/dotnet-client) on the .NET client for ASP.NET Core SignalR. |
| 43 | + |
| 44 | +## Feedback & Contributing |
| 45 | + |
| 46 | +`Microsoft.AspNetCore.SignalR.Client.Core` is released as open-source under the [MIT license](https://licenses.nuget.org/MIT). Bug reports and contributions are welcome at [the GitHub repository](https://github.com/dotnet/aspnetcore). |
0 commit comments