RunicToolkit.Hosting.CsWebUi
0.1.0-preview.30.1
dotnet add package RunicToolkit.Hosting.CsWebUi --version 0.1.0-preview.30.1
NuGet\Install-Package RunicToolkit.Hosting.CsWebUi -Version 0.1.0-preview.30.1
<PackageReference Include="RunicToolkit.Hosting.CsWebUi" Version="0.1.0-preview.30.1" />
<PackageVersion Include="RunicToolkit.Hosting.CsWebUi" Version="0.1.0-preview.30.1" />
<PackageReference Include="RunicToolkit.Hosting.CsWebUi" />
paket add RunicToolkit.Hosting.CsWebUi --version 0.1.0-preview.30.1
#r "nuget: RunicToolkit.Hosting.CsWebUi, 0.1.0-preview.30.1"
#:package RunicToolkit.Hosting.CsWebUi@0.1.0-preview.30.1
#addin nuget:?package=RunicToolkit.Hosting.CsWebUi&version=0.1.0-preview.30.1&prerelease
#tool nuget:?package=RunicToolkit.Hosting.CsWebUi&version=0.1.0-preview.30.1&prerelease
RunicToolkit.Hosting.CsWebUi
This package adapts CS-WebUI to the
browser-neutral contracts in RunicToolkit.Hosting.Abstractions. It serves a
local frontend directory without ASP.NET Core and supports CS-WebUI's automatic
browser selection, an explicitly selected installed browser, or an embedded
WebView.
The adapter remains prerelease while its upstream CsWebUi dependency is
prerelease.
using CsWebUi;
using RunicToolkit.Hosting.CsWebUi;
var factory = new CsWebUiBrowserHostFactory(
new CsWebUiAdapterOptions(
"wwwroot",
CsWebUiPresentationMode.Auto,
configureWindow: window =>
{
window.Bind("greet", static webEvent =>
WebUiResult.FromString($"Hello, {webEvent.GetString()}!"));
}));
Pass factory to WebUiModeRunner. The runner supplies an app:// entry URI;
the adapter accepts only the current application host, rejects credentials,
ports, queries, fragments, traversal, encoded separators, and control
characters, and translates the URI to a relative CS-WebUI root path.
BrowserWindowOptions size and resizability are applied before show. The title
is set after CS-WebUI establishes the client connection. The server is kept
private to the local machine. A disconnected client raises CloseRequested
and completes WaitForCloseAsync.
The native configuration callback runs after WebUiWindow creation and before
the window can be shown. It is intended for CS-WebUI Bind/BindAsync
registration; do not show or dispose the window from that callback.
CS-WebUI owns process-wide native state, so adapter dispatchers serialize native
work across hosts. Disposing a host closes only its owned windows; it does not
call the process-wide WebUiApplication.Exit or Clean methods.
Applications that want the shared high-level builder add the separate
RunicToolkit.Hosting.CsWebUi.App composition package. Keeping that dependency
out of this adapter allows custom hosts to use CS-WebUI without Generic Host.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- CsWebUi (>= 2.5.0-beta.4.3)
- RunicToolkit.Hosting.Abstractions (>= 0.1.0-preview.30.1)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on RunicToolkit.Hosting.CsWebUi:
| Package | Downloads |
|---|---|
|
RunicToolkit.Hosting.CsWebUi.App
High-level WebUiApp composition for native CS-WebUI frontends. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.1.0-preview.30.1 | 67 | 8/11/2026 |