https://github.com/webpx/webpx.web.healthui
A library for adding a minimal UI for Health Diagnostics in ASP.Net 8.0 or up.
https://github.com/webpx/webpx.web.healthui
Last synced: 5 months ago
JSON representation
A library for adding a minimal UI for Health Diagnostics in ASP.Net 8.0 or up.
- Host: GitHub
- URL: https://github.com/webpx/webpx.web.healthui
- Owner: WebPx
- License: mit
- Created: 2025-01-26T21:38:06.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-01-27T05:58:10.000Z (over 1 year ago)
- Last Synced: 2025-08-24T15:21:01.783Z (10 months ago)
- Language: HTML
- Homepage: https://webpx.github.io/WebPx.Web.HealthUI/
- Size: 7.06 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# WebPx.Web.HealthUI.Razor
A library for displaying a basic health check UI for your web application.
## Introduction
The Health Check UI is a basic UI that shows ou the Sevice Status, the Health Checks and the Health Check Results, so that you can easily see the status of your application.
The following scree shot shows the Health Check UI in action.

## Setup
To use the Health Checks in your project you can add both libraries
[Microsoft.Extensions.Diagnostics.HealthChecks] and [WebPx.Web.HealthUI.Razor] to your project.
1. Add required Nuget packages
a. You can add the required nuget packages to your project file
```xml
```
b. Or Install the packages in the Package Manager:
```
install-package Microsoft.Extensions.Diagnostics.HealthChecks
install-package WebPx.Web.HealthUI.Razor
```
c. Or Install the packages in the command prompt
```
dotnet add package Microsoft.Extensions.Diagnostics.HealthChecks --version 8.0.12
dotnet add package WebPx.Web.HealthUI.Razor --version 1.0.0
```
2. Add the depenencies from CDNJS to your libman.json file
or create a new libman.json file with the following content
```json
{
"version": "3.0",
"defaultProvider": "cdnjs",
"libraries": [
{
"provider": "cdnjs",
"library": "bootstrap@5.3.3",
"destination": "wwwroot/lib/bootstrap/",
"files": [
"js/bootstrap.bundle.min.js",
"js/bootstrap.bundle.min.js.map",
"css/bootstrap.min.css",
"css/bootstrap.min.css.map"
]
},
{
"provider": "cdnjs",
"library": "bootstrap-icons@1.11.3",
"destination": "wwwroot/lib/bootstrap-icons/",
"files": [
"font/fonts/bootstrap-icons.woff2",
"font/fonts/bootstrap-icons.woff",
"font/bootstrap-icons.min.css"
]
}
]
}
```
3. To customize where the files the template should find them, add the following code to your Program.cs file.
Remember just to change the paths if you have a different folder structure, do not include the .css or .js filename
```csharp
builder.Services.AddHealthUI(c =>
{
c.BaseUri = "/";
c.BootstrapPath = "/lib/bootstrap";
c.BootstrapIconPath = "/lib/bootstrap-icons";
});
```
4. You can also set this settings in your appsettings.json file
```json
{
"WebPx": {
"Health": {
"UI": {
"BaseUri": "/",
"BootstrapPath": "/lib/bootstrap",
"BootstrapIconPath": "/lib/bootstrap-icons"
}
}
}
}
```