Runic Application
Compose typed Windows and Views. Render with your frontend.
Runic Application connects explicit .NET Window and View types to ordinary TypeScript clients. The frontend owns its component tree; .NET owns ViewModel scopes, logical View lifetimes, commands, and operations.
Composition
Select a Window explicitly
A partial RunicWindow<TViewModel> declares the logical
window boundary. Dependency injection owns the Window's ViewModel scope; a
host adapter supplies native presentation and lifecycle.
Content
Views carry typed context
A partial RunicView<TViewModel> selects a content
contract and exposes a typed DataContext. The browser
acknowledges mount and unmount so .NET can create and dispose logical
Views as routes change.
Frontend
Keep rendering in the framework
The build emits normal TypeScript modules from the compiled .NET application. Use them from React, Vue, Svelte, Angular, plain TypeScript, or another frontend without adding a framework-owned transport layer.
Bindings
Connect Views to components
Generated clients share one runtime, @runic-artifex/views,
which includes a mock Bridge for frontend work without .NET. useView in the React, Vue and Svelte packages and injectView() in the Angular package connect and dispose a
client with the component that renders it. Svelte and Angular render the
selected View with an outlet; the React and Vue outlets and the command
helpers (useCommand, injectCommand) arrive
with SDK 0.7.
Calls
Use typed commands and writes
Generated clients expose snapshots, subscriptions, commands, property writes, and disposal. Writes return receipts and version conflicts; accepted operations stay owned by .NET through a browser reload.
Testing
Test both sides without a window
Runic.Application.Testing drives the real ViewModels and
generated Bridges in a .NET test, without a browser or native window.
Frontend tests run the generated clients against the mock Bridge in @runic-artifex/views. Typed drivers and generated mocks
arrive with SDK 0.7.
Examples
Compare Window and View patterns
The first Window introduces a single ViewModel and generated client. CommunityToolkit Notes exercises nested content and scoped Views. Reactive Notes shows routed ViewModels and multiple logical Views for one model.