Runic Application Views
On this page
- Navigation and model context packages
- Upgrading generated clients
- Upgrading from 0.13 to 0.14
- Upgrading from 0.14 to 0.15
- Upgrading from 0.15 to 0.16
- Upgrading from 0.16 to 0.17
- Upgrading from 0.17 to 0.18
- Upgrading from 0.18 to 0.19
- Upgrading from 0.19 to 0.20
- Upgrading from 0.20 to 0.21
- Upgrading from 0.21 to 0.22
- Upgrading from 0.22 to 0.23
Runic Application Views composes explicit .NET Windows and logical Views with
ordinary TypeScript clients. A RunicWindow<TViewModel> owns a window context;
a RunicView<TViewModel> declares a typed presentation contract. The build
inspects the compiled application after its MVVM source generators run and emits
C# attachments and TypeScript modules.
The browser framework owns the visual tree. .NET owns ViewModel scopes, View
construction, typed commands, property writes, and operation lifetimes. The
browser opens and closes a presentation of each View it shows, so a content
session can create and release its logical View as frontend routes change. Generated clients are framework-neutral;
React, Vue, Svelte, Angular, and plain TypeScript use the same contract. They
share one browser runtime, @runic-artifex/views,
which also provides a mock Bridge for development without .NET. The
React and
Vue packages, useView in
@runic-artifex/svelte and
injectView() in @runic-artifex/angular
connect and dispose clients with component lifetimes. Since SDK 0.11.0, a
SvelteKit frontend uses @runic-artifex/svelte with
@runic-artifex/sveltekit,
which prerenders its pages for the Window.
Start with getting started, follow
Windows and Views, step by step, or
add Runic to an existing app. Existing WPF applications can
adopt Runic incrementally, keeping their shell
and models while adding native navigation and optional embedded web Views. The
first Window is the smallest example; then read the
CommunityToolkit Notes and
Reactive Notes examples. The
package API and build properties are in the
Runic.Application.Views package guide.
The package is built from packages/dotnet/Runic.Application.Views, and its
types are in the Runic.Application.Views namespace; the
reference lists every package with its source folder.
Navigation and model context packages #
Since 0.7.0-preview.4, navigation and model contexts live in
Runic.Navigation.
It can be used independently of Views; Runic.Application.Views references it
transitively. Add using Runic.Navigation; for RunicNavigator, regions,
IRunicModelContext, RunicModelContext and RunicModelContextRegistry, then
recompile. There are no type forwards. ReactiveUI navigation helpers are in
Runic.Navigation.ReactiveUI (or its .Reactive flavor). The model-context
scheduling helpers, AddRunicReactiveModelContext() and
ReactiveSchedulers (RunicReactiveSchedulerProvider before 0.9.0), moved back to
Runic.Application.Views.ReactiveUI in 0.7.0-preview.7; replace
using Runic.Navigation.ReactiveUI; with
using Runic.Application.Views.ReactiveUI; for them.
Pages and navigation and
ViewModel state and threads show both in use. The
preview.4 migration tables
list the moved types.
Upgrading generated clients #
Rebuild after upgrading so the C# bridges and TypeScript clients regenerate
together, and add @runic-artifex/views to the frontend's dependencies.
- Connected client types are named
<Name>Client; the former<Name>Viewname is no longer generated. - Import
BridgeError,BridgeOperation*andFieldBaseline*from@runic-artifex/views. Generated modules no longer export them, soinstanceof BridgeErrorholds across modules. - Generated state types no longer contain
revision. snapshotreturns the last state after disposal, andsubscribeafter disposal delivers that state once and returns a no-op unsubscribe.- Generated C# files are named
<FullName>.Bridge.g.csand<FullName>.View.g.cs. The build removes the former files automatically. DateTimeOffsetvalues keep their offset on the wire, and outbound date values must be ISO 8601 strings.- Toolkit asynchronous commands and ReactiveUI commands with an argument publish
is<Name>Executing; nullable ReactiveUI command and interaction types areT | null. - Since SDK
0.11.0, regenerated clients need@runic-artifex/views0.11and TypeScript 5.2 or later, because the.d.tsfiles reference theesnext.disposablelibrary.connect<Name>()returnsPromise<<Name>Client & globalThis.Disposable>, sousingdisposes a client where the engine hasSymbol.dispose, and takes{ signal }to abort the connection. Clients generated by0.10keep working with the0.11runtime. - Since SDK
0.13.0, the generated clients, bridges and mocks speak Views protocol 4. Update every Runic NuGet and npm package to0.13.0together, rebuild, and reload open pages: a cached0.12page and a0.13host do not connect, and the page reports aprotocoldiagnostic. Code that uses generated clients compiles unchanged.TimeSpanvalues travel as ISO 8601 durations ("PT1H30M") instead of"01:30:00", a custom__runicBridgeimplementsrequest,onMessageandonConnectionChangeinstead ofcall, a customIBridgeTransportimplementsServeandBroadcastAsync, and the untyped mock names members (commands: { increment }) instead of route suffixes. Replace copies ofrunic-desktop-views.jsorrunic-cswebui.jskept outside the web content with the0.13copies. - Since SDK
0.13.0,snapshotandsubscribeshow a setter's value at once, until the state that includes it arrives. Await the setter's promise where the page needs .NET's confirmation, such as a "Saved" indicator. For inputs, prefer the field bindings of SDK0.14.0(useField,injectField); see forms and validation.
The 0.13.0 release notes list everything to check when upgrading, and the migration guide has before and after tables.
Upgrading from 0.13 to 0.14 #
Update every Runic NuGet and npm package to 0.14.0 together
(Runic.Application.Views.CsWebUi to 0.14.0-preview.1) and rebuild, so the
generated clients, bridges and mocks regenerate. Views protocol 4 does not
change: the new features are negotiated in hello, so a 0.13 page and a
0.14 host still connect and use whole values. Check these if they apply:
- Operations started before the upgrade. Every contract fingerprint
changes (
runic-bridge-contract-v6), so an operation that a0.13page started and recovers after the upgrade isunknown. - Notifications once per animation frame.
subscribelisteners get the newest state once per animation frame instead of once per frame, andsnapshotcan be up to one frame behind. A setter's value and the result of an awaited call are still delivered at once; the mock Bridge still delivers each push at once. See testing frontends. - Clients stay connected after unmount.
useView,injectViewandcreateViewControllerkeep a client forkeepAlivemilliseconds (2000 by default), and the next binding of the same connector takes it over. Tests that check that a route closes at unmount pass{ keepAlive: 0 }. - Requests before
hellowait up to 5 seconds for thehelloinstead of answeringno-helloat once, inInMemoryBridgeTransportand the mock Bridge too. - Text fields read checked-write receipts.
useTextField,injectTextFieldandcreateTextFieldControllerkeep the draft on arejectedorconflictreceipt and report it inerror, instead of dropping it; their state addstext,errorsandconflict. The new field API covers every member type; see forms and validation. - Validation messages. An empty or blank message crosses as
Invalid value.instead of"". The Runic Artifex forks are stable:RunicArtifex.ReactiveUI.Validation9.0.0andRunicArtifex.DynamicData10.0.0, so an application that references them moves to these versions and drops--prerelease. runicDevSession()is deprecated. A SvelteKit frontend usesrunic({ html: false })invite.config.tsand imports@runic-artifex/vite-plugin-runic/clientfromsrc/hooks.client.ts; the deprecated function still works in0.14. An Angular frontend keepsrunicDevSessionProxy()and loads the development client frommain.tsbehindngDevMode; its/__runic/statenow answers 200 with the state JSON instead of 204.- Platform services without a window.
IApplicationPlatformServices, registered byAddRunicPlatformServices()and returned byDesktopPlatformServices.ForApplication(), opens URIs and files and shows message boxes without a window. It replaces theDesktopPlatformServices.OpenUriAsync(uri)of 0.14 development builds, which 0.14.0 does not ship; see without a window. - Navigation hooks under
RunicModelContextrun in the model context, each in a turn of its own, as with WPF'sDispatcherModelContext. Set page state inInitializeAsyncorOnArrivedAsyncdirectly, don't block in a hook, and remove a wrapper that scheduled hooks itself; see ViewModel state and threads. - SDK tool exit codes.
dotnet runic,Runic.Createand the asset packer are built with Runic Command Line0.11.0. A failure on what a command found, such as a missing project (RAPPDEV1002), an invalid Views Window project (RAPPDEV1005), an existingsize --reportfile (RAPPSIZE1003), a missing packer source directory (RAS1001) or a non-emptyrunic-createdestination (RCREATE003), now exits 1 instead of 2; exit code 2 means that the command line itself is wrong. Human output writes the message without its leading code. Scripts test 1 or readfault.codefrom--format json. - CS-WebUI shows no "Connection with the backend is lost" banner, because
runic-cswebui.jsinstalls a WebUI event callback. Show the connection state yourself, for example fromuseBridgeConnection()as the template does. - Removed types fail with
CS0619. Code that still names a type removed in 0.9 or 0.13, such asIAsyncBridgeTransportorBridgeTestArguments, gets an error that names its replacement, for this release. - Toolchain floor. The build warns with
RUNICBRIDGE033for a .NET SDK older than 10.0.403 or a Bun older than 1.4.4.
The 0.14.0 release notes list everything to check, and the migration guide has before and after tables for each area, including tests, Windows, Nix and the CLI tools.
Upgrading from 0.14 to 0.15 #
Update every Runic NuGet and npm package to 0.15.1 together
(Runic.Application.Views.CsWebUi to 0.15.1-preview.1) and rebuild, so the
generated clients, bridges and mocks regenerate. 0.15.1 is 0.15.0 with
one fix:
a Svelte $effect that reads only client, error or pending from
useView no longer runs again with every state. Views protocol 4 does not
change: the new features presentation-epoch/1 and presented/1 are
negotiated in hello, so a 0.14 page and a 0.15 host still connect and
behave as in 0.14. Check these if they apply:
- A Runic Desktop executable references its server.
Runic.Desktopno longer references ASP.NET Core. AddRunic.Desktop.NativeServer, which needs no ASP.NET Core and which new projects use, orRunic.Desktop.Kestrelto keep ASP.NET Core Kestrel, to the executable that referencesRunic.Application.Views.Desktop,Runic.Application.Views.WpforRunic.Desktop; without either the build fails withRUNICDESK004. A library changes nothing. Keep Kestrel when the application uses ASP.NET Core itself, such asIConfigurationorIHostEnvironmentfromDesktopHostOptions.ConfigureServices: on the native server that callback receives a plain service collection with logging. An executable that opens no window sets<RunicDesktopServer>None</RunicDesktopServer>. See the presentation server. BridgeConnectionStatehas a fifth value,"closed". The application closed the window, and the state staysclosedwhen the connection then drops. AswitchorRecord<BridgeConnectionState, …>that handles every value no longer compiles until it handles"closed"; the template shows "The application closed this window."- Late commands of an earlier page. Replace a presentation number kept in
state and compared in each command with
[RunicPresentationScoped]on the command andRunicPresentation.Renew(this)where the page changes; replace aUiRenderedcommand that the page called after a frame withRunicPresentation.WaitForPresentedAsync, and a close-acknowledged command withCloseAsync(timeout)andRunicWindowCloseResult.PagesAcknowledged. See commands scoped to their page. - Content presented again pushes its state. When a slot shows other
content and then the earlier content again, the Bridge pushes that content's
state, so a test that expected no push after
Main = b; Main = anow sees astatepush of the resumed route. - Answered dialogs no longer come back. A retained result entry whose
caller cancelled, or that called
DismissAsyncwhile another entry covered it, is retired by the Back of the entry above it, which resumes the entry below. Code that waited for the dialog to reappear to leave it can drop that step. A prompt stack of your own beside a dialog region becomesNavigationAdmission.Queue, and aCanLeaveTabAsync()of your own becomesAskOnParentRetainorConfirmDepartureAsync; see queue dialogs. runicDevSession()is removed. A SvelteKitvite.config.tsthat still imports it fails to load: userunic({ html: false })and import@runic-artifex/vite-plugin-runic/clientfromsrc/hooks.client.ts.- CS-WebUI embeds its frontend. A CS-WebUI project with
RunicApplicationFrontendDelivery=Embedded, which built asFileswithRUNICBRIDGE030, now serves the frontend from the assembly, and its output has nowww/; remove the property to keepwww/. Code that extracted an embedded frontend to a folder forSetRootFolderbecomesRunicCsWebUiHostOptions.Assets, and a wrapper that filtered an archive by folder becomesarchive.Subdirectory("folder"). See embed and serve assets. - Embedded archives are checked at build time.
AssetArchive.ReadEmbeddedchecks the manifest and ZIP directory at load and inflates each asset when it is first requested; the build checks every archive it packs, and aRunicAssetsEmbeddedArchivethat is not a valid archive fails withRAS2006. CallValidateAsync()to check every digest at run time.AssetArchive.ReadandReadAsyncstill check every asset. - ReadyToRun publishes. A publish with
-p:PublishReadyToRun=trueno longer fails withNETSDK1191; remove a workaround that passed the property to the application project only. See choose the publish mode. - A slow WebView2 start shows the window early. On Windows, a window whose
WebView2 is not ready within 1.5 seconds appears titled
Loading…with a loading surface. UI automation that looks for the page waits for the page's document or title, not only the window. A user who closes the window then closes it:OpenWindowAsyncreturns it closed and no fallback opens. See the early first window. - A failed browser fallback throws
DesktopPresentationException. When theEmbeddedThenBrowserfallback browser fails too, the exception keeps itsCodeandCategory, and itsInnerExceptionis the browser'sDesktopException.catch (DesktopException)still matches; a check for the exact type does not. - macOS serve-only starts no AppKit. With
RUNIC_APPLICATION_SERVE_ONLY=1the process has no Dock icon and gets no open-document or open-URL events; stop it with Ctrl+C, SIGTERM or a line on standard input. - Windows administration error categories. A component that is not
installed or registered, such as the Group Policy Management Console or a
WMI provider, is
AdministrationErrorCategory.NotInstalledinstead ofUnavailable, and several native errors moved fromNativeFailuretoNotFound,InvalidData,UnavailableorConflict; see Windows administration. - Vue's
commit()resolves with the field's state, as in React, Svelte and Angular, soif ((await title.commit()).error === undefined) …works. Code that awaited it and then readtitle.errorstill works.
The 0.15.0 release notes list everything to check, and the migration guide has before and after tables for each area, including the native server's library version and Nix.
Upgrading from 0.15 to 0.16 #
Update every Runic NuGet and npm package to 0.16.0 together
(Runic.Application.Views.CsWebUi to 0.16.0-preview.1) and rebuild, so the
generated clients, bridges and mocks regenerate. 0.16.0 only adds APIs. Views
protocol 4 does not change: the new wire members are features negotiated in
hello, such as view-requests/1, field-paths/1 and navigation-path/1,
so a 0.15 page and a 0.16 host, or the reverse, still connect and behave
as in 0.15. Check these if they apply:
- CS-WebUI needs the
0.16page and host for its security fix. A page that reloaded, or another browser that connected right after a page left, could receive the pushes and questions of the page that had just closed. Withrequest-session/1each request names its page's session, and each connection gets a key that no later connection reuses. Replace any copy ofrunic-cswebui.jsthat the application keeps outsidewww/; a0.15page on a0.16host is only partly protected. A hand-written Views client listsrequest-session/1in itshelloand sends its session with each request. See who is connected. ConnectionKeyis the window's key. On CS-WebUI and the in-memory test transport,RunicInteractionInvocation.ConnectionKeyis nowconnection-1#1or0:1#2instead of the transport's key. Compare it withRunicViewDriver.ConnectionorIRunicConnections, and useIRunicConnections.Callerinstead of tellingMultiClientpages apart through a command argument.- A page answers questions that used to fall back to .NET. A ReactiveUI
interaction asked by a command on another route of the window, or by a
menu-bar command, now reaches a page that has a handler mounted, also a
0.15page on a0.16host. Keep the .NET handler only for when no page is mounted. See ask the page and await its answer. - A page's command identity ends with the command. A timer,
Task.Runor background loop that a page's command started no longer asks that page;RunicInteractionInvocation.Currentisnullthere. EnterRunicInteractionInvocation.EnterWindow(viewModel)for long-lived work that should ask the window's page. An async ReactiveCommand run by an in-page menu click asks its page before its firstawait. - Field kinds and text.
decimal,DateOnly,TimeOnly,DateTimeandDateTimeOffsetmembers have the kindsdecimal,date,timeanddatetimeinstead oftext; treat an unknown kind likevalue. Empty text in a nullable one isnull, and in a non-nullable one aninvalid-texterror.timetext is10:30, adatetimefield shows the page's local time, and number text no longer accepts0x10or0b1. Once the application sets the window's language withIRunicWindowLocale, number, date and time fields without their ownlocalefollow it: give a field bound to<input type="number">ortype="date"locale: null(bindFielddoes that itself). See upgrading from 0.15 in forms and validation. - Departure guards see the last keystrokes. With a
0.16page and host, the window's pages write their drafts before a departure guard runs (field-flush/1), so a guard can run up to 1 second later. In tests, setInMemoryBridgeTransport.FieldFlush. - Recent documents on Windows and Linux.
DesktopHost.NoteRecentDocumentAsync(AddRecentDocumentAsyncsince 0.21) andClearRecentDocumentsAsync, which did nothing outside macOS, now add to and clear Explorer's Recent items and Jump List andrecently-used.xbel. Guard a call you don't want there. See recent documents. DesktopWindow.FocusAsyncrestores a minimized window on Windows, as on macOS and GTK; an extra restore before it can go.- Your own
IRunicWindowServicestill compiles: the new members, such asFindOrOpenAsyncandOpenForResultAsync, throwNotSupportedExceptionuntil it implements them. - CS-WebUI serves blobs and uploads from a loopback endpoint of each
window, on another origin than the page. A page
Content-Security-Policyallowshttp://localhost:*forimg-src,media-srcandconnect-srcto use them. See blobs and uploads. - A native server library of your own (
RunicDesktopNativeServerLibraryDirectory, NixrunicServer) is built from0.16: its C ABI is version 3, and an older library fails at startup withnative-server-unavailable. Applications that referenceRunic.Desktop.NativeServerget the matching library. - Serve-only test harnesses accept a
RUNIC_APPLICATION_WINDOW=<url> <Window type>line after eachRUNIC_APPLICATION_URL=line, and tests that compare the in-memory transport's messages exactly expect asessionand the new features in itshello. See behaviour that 0.16 tests meet.
Code of your own can often become a 0.16 API: a state flag the page watched to
focus a field becomes a ViewRequest<T>;
a dictionary of open windows becomes
FindOrOpenAsync; a saved
baseline for IsDirty becomes
RunicEditSession<T>;
a command per cell becomes a
row editor; a
rebuilt menu bar for a check mark becomes
IRunicMenuCheckedSource; a theme switch
that reloaded the page becomes
SetColorSchemeAsync; and a
fake file dialog of your own becomes
AddRunicTestPlatform(). New in
0.16.0 as well: document tabs,
saved navigation and deep links,
Back and the URL,
query collections,
power and session events
and page errors in .NET logs.
The 0.16.0 release notes list everything to check, and the migration guide has before and after tables for each area, including tests.
Upgrading from 0.16 to 0.17 #
Update every Runic NuGet and npm package to 0.17.0 together
(Runic.Application.Views.CsWebUi to 0.17.0-preview.1) and rebuild, so the
generated clients regenerate. Applications that use Runic Translations move
every Translations package to 0.9.1. 0.17.0 only adds APIs, and its new
wire members are Views protocol 4 features negotiated in hello
(client-languages/1 and appearance/1), so a 0.16 page and a 0.17 host,
or the reverse, connect and behave as in 0.16. Check these if they apply:
- CS-WebUI applications should update for the security fix. A window's page server and blob endpoint now hold both loopback addresses of their port; see the CS-WebUI fix and the advisories on the Releases page.
ViewOutletandRegionOutletsshow the English "No web component is registered for …" alert only in development builds. Production builds render nothing and report the kind once through the page's error reporting; passmissingto render your own text.- Window locales fall back to their parent. A locale the page's runtime
does not have, such as
de-CH, setsdebefore the page reports an error; a parent in another script, such aszhforzh-Hant-TW, is skipped. - Native windows follow the Window's locale. On Windows and Linux a Runic
Views Desktop window opens with the layout direction and web view language of
its
IRunicWindowLocaleand mirrors when it changes.DesktopWindowOptions.LayoutDirectionandLanguagestill win. - Shortcut labels and dialogs. Windows menu shortcut labels use the
keyboard layout's modifier names, such as
Strg+S, and the GTK 3 file chooser shows GTK's own translated buttons. - Tests that compare the in-memory transport's messages exactly see
client-languages/1with"languages":[]andappearance/1in itshello, and anappearancepush with every membernullafter it. Windows thatRunicWindowTestHost.CreateWindowAsyncopens use the application'sRunicValidationOptionsand the Window'sMaximumUploadBytes. - Packaging. Linux
.desktopfiles no longer XML-escape the name and description. Once the project setsRunicApplicationLocales, a manifest copied intopackaging/before 0.17 fails withRAPPPKG1006, which names the field to add.
New in 0.17.0: the application's language with Runic's
own text in English and German and the --translations template,
appearance beyond light and dark,
shared clients,
owner-less file dialogs for CS-WebUI, and, experimental,
hosted applications.
The 0.17.0 release notes list everything to check, and the migration guide collects them.
Upgrading from 0.17 to 0.18 #
Update every Runic NuGet and npm package to 0.18.0 together
(Runic.Application.Views.CsWebUi to 0.18.0-preview.1) and rebuild, so the
generated clients regenerate. No public .NET API was removed or changed. Check
these if they apply:
- Runic Translations 0.10 and Runic Command Line 0.12.
Runic.Application.Views.Translationsrequires Translations[0.10.0, 0.11.0), so move every Translations package to0.10.0.dotnet-runic,Runic.Createand theRunic.Assetspacker bundle Command Line0.12.0; an application that uses Command Line itself moves to0.12.0(see Upgrading from 0.11). - The native presentation server's C ABI is 5.
Runic.Desktop0.18.0binds only ABI 5, so aRunic.Desktop.NativeServerof another version fails at the first window withnative-server-unavailable. Use the same version of both. An application that links the server itself depends on therunic-servercrate at thev0.18.0tag. describeBridgeErrorshows Runic's sentence for aBridgeError's reason or kind and never itsmessage:rejectedwithinvalid-inputreads "The input is not valid.", and an emptyintegerfield reads "Enter a whole number." Application text still reaches the page throughFieldError, andconfigureRunicTextreplaces Runic's wording.- GTK 4 windows show
DesktopPlatformTexts.LoadingTitle("Loading…") until the page has a title, instead of "Runic Desktop". - A
PropertyChangedthat names a bridged member refreshes only that member, so a getter with side effects runs less often. A collection or observed sub-object replaced under another member's notification now publishes its later changes. - Tests that compare a host's or guest's
helloexactly seeregion/1(andregion-component/1where allowed), and the Views protocol offershosted-regions/1. - Generated union encoders are typed: regenerate generated clients and mock doubles.
dotnet runic doctorrequires the .NET 10 runtime (dotnet-runtime), anddotnet runic devstops withRAPPDEV1013when it is missing. The .NET 11 SDK (11.0.100) is accepted fornet10.0applications.
New in 0.18.0, experimental under RUNICDESK103: a host can show a guest
application's Window in a region of its own page (region mode), or a guest's
Views as a component in its document (trusted component mode); see the SDK's
hosted regions guide.
An elevated host can host an elevated guest of the same user. Stable: exact
window bounds and a run-time minimum size (DesktopWindow.SetBoundsAsync,
SetMinimumSizeAsync, DesktopWindowState.Bounds), and Runic's own page text
in German.
The 0.18.0 release notes list everything to check, and the migration guide collects them.
Upgrading from 0.18 to 0.19 #
Update every Runic NuGet and npm package to 0.19.0 together
(Runic.Application.Views.CsWebUi to 0.19.0-preview.1) and rebuild, so the
generated clients and Bridges regenerate. No application API was removed.
Check these if they apply:
- Rebuild every assembly that contains generated Bridges, including a
separate
RunicApplicationFrontendModelAssemblyand ViewModel libraries that other applications reference. The Bridge runtime inRunic.Application.Views.Generatedis no longer generic over the ViewModel, so a Bridge that the 0.18 generator wrote fails to load. The host reports it at the first Window or View asRUNICBRIDGE038, which names the assembly to rebuild. The wire protocol and the generated TypeScript client are unchanged. A hand-written Bridge, such as a test double, derives fromViewModelBridge, passestypeofof its ViewModel and casts the ViewModel in each descriptor lambda. - Runic Translations 0.11 and Runic Command Line 0.13.
Runic.Application.Views.Translationsrequires Translations[0.11.0, 0.12.0), so move every Translations package to0.11.0.dotnet-runic,Runic.Createand theRunic.Assetspacker bundle Command Line0.13.0; an application that uses Command Line itself moves to0.13.0(see Upgrading from 0.12). - The tools' help and usage errors follow Command Line 0.13: help lists
arguments by their placeholder (
<source-directory>), names options in[requires: …]and[conflicts: …]by their spelling, and shows no[default: False]for flags. In--format json,RCLI1005'sargumentshold the placeholder; a script that read the ID from them reads the newbindingmember instead. - A Windows title bar without a forced colour scheme follows the system's
dark mode. A WebView2 window with
DesktopColorScheme.NoPreference, and a WPF window afterSetColorSchemeAsync(NoPreference), takes the system's app mode. SetLightfor a light title bar, which also pins the page'sprefers-color-scheme. RUNICBRIDGE039, a new generator warning, reports a[RunicOperationClose]declaration that reaches no operation. Only code that uses the experimental close drain can meet it.RunicTestWindowPresentation.AllFeaturesnow includesSidePanel,MaximizeandPlacement; a test that comparedFeatureswith a list of its own adds them.
New in 0.19.0, experimental: a side panel beside the window's page, by
which the window grows (OpenSidePanelAsync, RUNICDESK104; see the SDK's
side panel guide),
a close drain that keeps a Window open until its accepted work has finished,
also at shutdown (RunicWindowOptions.CloseDrain, [RunicOperationClose],
RUNICDESK105), and an
appearance override per hosted region
(RUNICDESK103). Stable: DesktopWindow.MaximizeAsync, RestoreAsync and
SetPlacementAsync, the same on IRunicWindowPresentation for ViewModels,
WPF and hosted windows, per-window services for a window the application
opened itself (DesktopPlatformServices.AttachWindowServices), and
AcceptedWorkScope.WaitForAcceptedAsync. A NativeAOT executable grows by
about 24 KiB per bridged ViewModel instead of about 118 KiB.
The 0.19.0 release notes list everything to check, and the migration guide collects them.
Upgrading from 0.19 to 0.20 #
Update every Runic NuGet and npm package to 0.20.0 together
(Runic.Application.Views.CsWebUi to 0.20.0-preview.1) and rebuild, so the
generated clients and Bridges regenerate. No application API was removed, and
the wire protocol is unchanged: the new Views protocol features
(trace-context/1, handler-timing/1) are negotiated, so a 0.19 page and a
0.20 host connect. Check these if they apply:
- Runic Translations 0.12; Command Line stays at 0.13.
Runic.Application.Views.Translationsrequires Translations[0.12.0, 0.13.0), so move every Translations package, NuGet and npm, to0.12.0(see Upgrading to 0.12.0). With the Translations Vite plugin 0.12, an edited message updates in place underdotnet runic dev, and Runic Inspect marks the page's messages and edits them; an earlier plugin reloads the page and offers no editing. - Bridge warnings fail a build that treats warnings as errors. The Bridge
analyzers now report
RUNICBRIDGE013,028,031,032,034,039and053as compiler warnings, and the MSBuild warnings of the generator and the Views build targets (015,019,020,029,030,033) are errors too underTreatWarningsAsErrors. Fix the declaration, or keep it a warning withWarningsNotAsErrors(or hide it withNoWarn). - WebKit's remote inspector opens only in Development on Linux. Outside
Development the GTK 3 and GTK 4 hosts remove
WEBKIT_INSPECTOR_SERVERandWEBKIT_INSPECTOR_HTTP_SERVERfrom the process's environment before their first web view. To inspect a build remotely, run it withDOTNET_ENVIRONMENT=Development; see debugging. - Generated clients are two files:
<view>.tsand<view>.contract.d.tswith a declaration map, so Go to Definition opens the C#. Imports and the built JavaScript are unchanged; commit the new files of a committed generated directory, and a library that emits declarations withtsccopies the.contract.d.tsfiles beside them. - Bun bundles the development build of
@runic-artifex/viewsby default.vite build,ng buildandbun build --productionbundle the production build; pass--productiontobun build, or setNODE_ENV=productionfor aBun.buildscript, when you build a release page. The Views MSBuild targets run an optimized build's frontend build withNODE_ENV=production. dotnet runic doctor --format jsongives each check ahelpUri. A validator that holds an earlier copy of therunic.application.tool.doctor/1schema rejects 0.20's payload; update the copy.
New in 0.20.0, for development only and absent from production builds: the
development source map from each Bridge member to its C#, Go to Definition from
generated clients to the C# handlers, Bridge calls in the browser's Performance
panel and in the dock, Runic Inspect (with Edit for translations), C#
handler timing and one trace from the page to .NET, an IDE contract and
dotnet runic dev --no-window, launch profiles and an optional VS Code setup
in the template, and the Bridge analyzers while you type. See
debugging an application and
tracing Bridge calls. The template's Vite frontends
compile their catalog with the Translations Vite plugin, the Angular template
can build with Vite (--angular-build vite), @runic-artifex/angular ships in
the Angular Package Format, and an Angular guest can be shown in trusted
component mode (experimental, RUNICDESK103).
The 0.20.0 release notes list everything to check, and the migration guide collects them.
Upgrading from 0.20 to 0.21 #
Update every Runic NuGet and npm package to 0.21.0 together
(Runic.Application.Views.CsWebUi to 0.21.0-preview.1) and rebuild. The
wire formats are unchanged, but 0.21 renames API members from the 0.21 API
review, so code that uses one of them needs an edit. Check these if they apply:
Runic Translations 0.13; Command Line stays at 0.13.
Runic.Application.Views.Translationsrequires Translations0.13, so move every Translations package, NuGet and npm, to0.13.0and replaceTranslationContext.CreateBuilder().Add(with.AddCatalog((see Upgrading to 0.13.0)..NET renames. Rename the calls; nothing else changes, and saved navigation paths load unchanged (a selection's index stays
"selected"in the JSON):0.20 0.21 DesktopHost.NoteRecentDocumentAsync(path)DesktopHost.AddRecentDocumentAsync(path)DesktopWindowCapabilities.WindowPlacementDesktopWindowCapabilities.Placement(same value)IDesktopWindowBoundsHost,IDesktopWindowShowStateHost(custom window hosts only)IDesktopBoundsWindowHost,IDesktopShowStateWindowHostNavigationSelectionPath.Selected,RunicRegionCollectionState.SelectedSelectedIndexMaximumWindowUploadBytes(RunicWindowOptions,WindowContentSessionOptions)MaximumPendingUploadBytes, now also on the host optionsRunicWindowsChangedEventArgs.Opened(bool)Change == RunicWindowsChange.Opened(an open enum withOpened,Closed)RunicUpload.SaveAsAsync(path, overwrite)RunicUpload.SaveToFileAsync(path, overwrite)RunicServeOnlyTestPlatform.EnqueueOpenFile,EnqueueMessageBoxAnswer,EnqueueContextMenuChoice,SetClipboardText, …platform.FileDialogs.EnqueueOpen,MessageBoxes.EnqueueAnswer,ContextMenus.EnqueueChoice,Clipboard.SetText, …, as onRunicTestPlatformExperimental APIs (
RUNICDESK103toRUNICDESK105). Trusted component mode's npm side moved to./experimental: importdefineRunicComponent,connectComponentBridgeand theRunicComponent*types from@runic-artifex/views/experimental, andrunicfrom@runic-artifex/vite-plugin-runic/experimentalforrunic({ component }); the./componententry is gone without an alias. In .NET,RunicHostedDialogKind.OpenFolder(s)becameOpenDirectoryandOpenDirectories,RunicHostedWindow.PresentationDesktopWindow, a region'sDetachAsync,MoveToAsyncandSetAppearanceAsyncreturnValueTask, a detachReasonis the open enumRunicHostedRegionDetachReason, the side panel refuses withDesktopSidePanelRefusal.Closedwhen the window closes during a call, andRunicCloseDrain.KeepsWindowbecameKeepWindow. See hosted regions.Development format IDs are dotted. The Bridge source map is
runic.views.bridge-sources/1and/__runic/handlersanswersrunic.vite.handlers/1. A tool of your own that readssources.jsonor/__runic/sourcesaccepts the new name; the Runic extension for VS Code 0.21.0 reads both.Internal MSBuild names start with
_Runic. A project that ran its own targetBeforeTargetsorAfterTargetsone of the twelve renamed targets and properties (such asRunicDesktopValidateServer) hooks onto an MSBuild target instead. The documented extension pointsRunicViewsGenerateBridge,RunicViewsBuildFrontendandRunicViewsCopyFrontendare unchanged.WebView2's debugging endpoint opens only in Development. Outside Development the WebView2 host removes
WEBVIEW2_ADDITIONAL_BROWSER_ARGUMENTS, so a release opens no DevTools Protocol endpoint; run a build withDOTNET_ENVIRONMENT=Developmentto debug it that way.DesktopWindowOptions.BrowserArgumentsare not changed.The development server admits fewer clients.
/__runic/stateand/__runic/diagnosticsanswer only loopback andRUNIC_DEV_ALLOW, so a tool that read them from another machine needs it in the allow list; see debugging.Kept View clients follow their Bridge. A client that a binding keeps for
keepAliveis taken over only while it uses the Bridge it connected over:installMockBridgereleases the previous Bridge's kept clients, andreleaseKeptViews()from@runic-artifex/views/mockreleases them in a suite that keeps one Bridge.Linux capabilities count as elevated for a hosted guest (
RUNICDESK103); see hosted applications.SvelteKit security updates. New SvelteKit apps get
@sveltejs/adapter-static4.0.1 (GHSA-jf9x-2fg2-hx4w) and@sveltejs/kit3.1.1 (GHSA-mw6w-2fmv-pvw3). The template's static output is not affected; move an existing app to them to keepnpm auditquiet.
New in 0.21.0, for development only: JavaScript debuggers on Linux through
dotnet runic dev's CDP adapter (preview), dotnet runic dev --browser and
the Window in Chrome configuration, WebView2's Open DevTools and DevTools
extensions, the Runic DevTools extension (which dotnet runic dev loads into
the Window's WebView2 on Windows, and Chrome and Edge load unpacked), Runic state in
React DevTools and Vue DevTools, and custom object formatters; see
debugging an application. Also new:
NavigationSelectionPath.ToJson() and FromJson, and
injectTextLocale() and the field types in @runic-artifex/angular.
The 0.21.0 release notes list every change.
Upgrading from 0.21 to 0.22 #
Update every Runic NuGet and npm package to 0.22.0 together
(Runic.Application.Views.CsWebUi to 0.22.0-preview.1) and rebuild. The
generated TypeScript and the wire protocol are unchanged. Check these if they
apply:
- Runic Translations 0.14; Command Line stays at 0.13.
Runic.Application.Views.Translationsrequires Translations[0.14.0, 0.15.0), so move every Translations package, NuGet and npm, to0.14.0, and keepRunic.TranslationsandRunic.Translations.Buildat the same version: catalogs that 0.14 generates need its runtime (RMF2 runtime ABI 4). See Upgrading to 0.14.0. - Load
runic-views.js(deprecated host-named copies). The host packages copy their Views client intowww/asrunic-views.jsand, until 0.23, also asrunic-desktop-views.js(Runic Desktop) orrunic-cswebui.js(CS-WebUI). A page that loads the host-named copy still works in 0.22 but logs one console warning; 0.23 removes the copy, which saves 5 KB (Runic Desktop) or 21 KB (CS-WebUI) per publish. Load<script src="runic-views.js"></script>afterwebui.js, as the templates already do. A project that references more than one host, such as Runic Desktop and CS-WebUI, setsRunicApplicationHost(desktoporcswebui), or the build copies norunic-views.js(warningRUNICBRIDGE019). An application that keeps its own copy under the old name gets the same warning; rename it torunic-views.js. - The side panel and the close drain are stable. Their
[Experimental]attributes are gone and their API is supported like the rest of its package. RemoveRUNICDESK104andRUNICDESK105from<NoWarn>and their#pragma warning disablelines (a leftover suppression is harmless), and importonBridgeDrainingfrom@runic-artifex/views: the@runic-artifex/views/experimentalimport still works in 0.22, marked@deprecated, and 0.23 removes it. Hosted applications (RUNICDESK103) stay experimental. - A RID-specific publish ships only its own OS's platform code. A
dotnet publish -r <rid>for Windows, macOS or Linux, framework-dependent or self-contained without trimming, leaves the other operating systems'Runic.Platformassemblies out. Code that calls another operating system'sRunic.PlatformAPI from a method that also runs on this one getsFileNotFoundException; move the call into a method of its own or setRunicPublishAllPlatformAssemblies. See shipping. RunicDesktopServer=Noneturns the presentation server off, also when the project referencesRunic.Desktop.Kestrel: a window then fails withpresentation-server-unavailable. Build warningRUNICDESK007reports the combination; removeRunicDesktopServerto use the referenced server.- The asset archive format. An archive with duplicate content is written as
runic.assets.archive/2, which Runic.Assets 0.21 and earlier cannot read. An application that embeds an archive packed with 0.22 throughRunicAssetsEmbeddedArchiveneeds Runic.Assets 0.22 too. - The
(WebView2 script debugging)launch profile is gone from the template: it did not work in Visual Studio 2026. Delete the entry with"jsWebView2Debugging": truefrom an existing project'sProperties/launchSettings.json, and use Runic DevKit's Debug the Window in Visual Studio (debugging). To add the template's new.vsconfigto an existing project, copy it from a new one into the directory of its solution. - The editor extensions are Runic DevKit. In VS Code it is
runic-artifex.runic-devkit(wasrunic-artifex.runic), on the VS Code Marketplace; the template's.vscode/extensions.jsonnames the new ID. In Visual Studio 2026 it isrunic-artifex.runic-devkit-vs(was Runic MF2 Translations), on the Visual Studio Marketplace (Extensions → Manage Extensions, search for "Runic DevKit"). Both VSIX files are also on the runic-editors 0.22.0 release. Uninstall the former extension. - CS-WebUI's loopback server is stricter on Linux and macOS than .NET's
HttpListener: it answers400to ambiguous body framing, bare CR or LF line ends, dot segments and repeatedHost,Originor upload headers, and bounds request heads, connections and idle time. The endpoint's URLs, responses and checks (Host, origin, upload token, loopback peers) are unchanged; Windows keeps http.sys. - Angular CLI starters move
@angular/buildand@angular/clito 22.2.7 and no longer overridevite. An existing Angular CLI project can remove itsviteoverride (inpackage.json, and for pnpm inpnpm-workspace.yaml) after moving to@angular/build22.2.5 or later. dotnet runic doctoraccepts the npm 11 that Node 24 and 26 ship, from 11.12.1, with a warning that names the certified npm 12.2.0. Itscompatibility-setcheck now checks only the train's packages: runic-sdk's own, which must match exactly, and the Runic Command Line and Runic Translations packages, which warn when older than the train's or of another minor. Other packages whose IDs start withRunic, such asRunicArtifex.DynamicData, no longer fail it.
New in 0.22.0: smaller NativeAOT executables (generated Bridges share their
codecs, getters and command runner, CS-WebUI's own loopback server on Linux and
macOS, fewer framework generics and features that an application does not use),
development-only views and members ([RunicDevelopmentOnly]) and the
smallest-executable settings in
measure and tune,
single-file publishing of Views applications and the size of each publish mode
in shipping, and for
development: Runic DevKit for Visual Studio, CS-WebUI pages in a JavaScript
debugger (--debug-endpoint, port 9225), absolute vite dev source maps,
dotnet runic dev stopping on its standard input (RUNIC_DEV_STOP_ON_INPUT),
and Visual Studio's F5 building after a frontend-only edit; see
debugging an application. Fixed: dotnet runic dev
starts npm and pnpm on Windows, page-relative URLs and the dock's icon under a
Vite or Angular development server, Runic Inspect's open-in-editor on Windows,
Edge fallback windows under a compatibility layer, and the Linux CDP adapter's
stops after a reload or restart.
The 0.22.0 release notes list every change, and the migration guide collects them.
Upgrading from 0.22 to 0.23 #
Update every Runic NuGet and npm package to 0.23.0 together
(Runic.Application.Views.CsWebUi to 0.23.0-preview.1) and rebuild, so the
generated clients and Bridges are regenerated. Views protocol 4 is unchanged:
a 0.22 page and a 0.23 host still connect, and Bridges that 0.22's generator
wrote keep working with the 0.23 runtime. 0.23 is a consolidation release
before 1.0 and removes what 0.22 deprecated. Check these if they apply:
- Removed: the host-named Views client scripts.
runic-desktop-views.js(Runic Desktop) andrunic-cswebui.js(CS-WebUI), deprecated in 0.22, are gone: the host packages copy their Views client intowww/only asrunic-views.js, which saves 5 KB (Runic Desktop) or 21 KB (CS-WebUI) per publish. A page that still loads the old name gets a 404 for it and no Bridge, so its Views never connect; the build reports warningRUNICBRIDGE019naming the page. Load<script src="runic-views.js"></script>afterwebui.js, as the templates do. A project that references more than one host setsRunicApplicationHost(desktoporcswebui). A copy under the old name that the application keeps itself is served but not updated; rename it. Awww/folder of an earlier build keeps the old copy untildotnet clean. - Removed:
onBridgeDrainingfrom@runic-artifex/views/experimental. Import it from@runic-artifex/views, the same function; an import from./experimentalnow fails to compile or bundle. - Removed: the error tombstones of types removed in 0.9 and 0.13, such as
RunicBridgeJsonIgnoreAttribute,IBridgeArguments,RunicReactiveSchedulerProviderandINativePickerOwner. Code that still names one fails withCS0246instead ofCS0619; the migration guide names the replacements. - Removed: vite-plugin-runic's reader of the 0.20 source-map name
runic-bridge-sources/1. Only a 0.20 generator writes it; rebuilding with 0.23 regenerates the map. dotnet runic dev --browserhas an address of its own for each run,http://<label>.localhost:9224/, and admits one browser by a one-time code.http://127.0.0.1:9224/andhttp://localhost:9224/answer 403. In aWindow in Chromelaunch configuration generated before 0.23, replace"url": "http://127.0.0.1:9224/"with"file": "${workspaceFolder}/obj/runic/dev-browser.html", as the template now does; a configuration that matches by URL (urlFilter) useshttp://*.localhost:9224/*. The session file'sbrowser.urlis now a pattern; a reader opensbrowser.codeFileinstead. The template'sAttach to the page (JavaScript)configuration names"address": "127.0.0.1"; add it to one generated earlier. See the page in Chrome.- Runic Translations 0.15.1 and Runic Command Line 0.14.
Runic.Application.Views.Translationsrequires Translations[0.15.1, 0.16.0), so move every Translations package, NuGet and npm, to0.15.1, and keepRunic.TranslationsandRunic.Translations.Buildat the same version: Runic's own catalog is generated for RMF2 runtime ABI 5. Translations 0.15.1 fixes how external and overlay packs are loaded; generated ESM carries its own runtime, so an application with ESM output regenerates it with 0.15.1 (a build with the 0.15.1 Vite plugin or tool does that). An application that uses Command Line itself moves to0.14.0, whichRunic.Translations.CommandLine0.15 requires. See Upgrading to 0.15.1 and Command Line 0.14.0. - The application icon (#1207). When
icons/icon.png(or the fileRunicPackageIconnames) exists and the project sets noApplicationIcon, the build derives the Windows executable's icon from it, and Runic Desktop windows withoutIconFileshow it on Windows and on macOS outside a bundle. An icon that is not a square PNG of at least 256 px is warningRUNICICON001toRUNICICON003, which fails a build that treats warnings as errors: replace the icon or setRunicApplicationIconGenerationEnabled=false. A project from an earlier template can deleteicons/icon.icoand itsApplicationIconline. See the application icon. - Bridge blobs leave a trimmed publish that does not use them. A trimmed
or NativeAOT publish in which no Bridge holds a
RunicBlobor takes aRunicUploadturnsblobs/1off, soclient.uploadrejects withunavailable. Set<RunicBridgeBlobs>true</RunicBridgeBlobs>when only reflection reaches aRunicBlob.RunicBridgeBlobsandRunicDevelopmentOnlyViewswarn on a value other thanautoortrue(RUNICBRIDGE075). See measure and tune. - Questions longer than ten minutes. Rebuild the frontend with 0.23: a
page built with
@runic-artifex/viewsbefore 0.23 aborts an interaction's handler after ten minutes, whatever its lifetime. - Runic's editor extensions. Update Runic DevKit to 0.23.0 once it is
published; it needs
dotnet-runic0.23 for frontend errors in the error list.
New in 0.23.0:
- For application code: an interaction's lifetime with
[RunicInteractionTimeout], including questions without a deadline (prompts); operation progress through anIProgress<double>parameter (operations); drops onto the side panel, withInSidePanel(desktop services); a menu bar item that opens the developer tools, now also WebKit's Web Inspector on Linux, which the template declares as View ▸ Developer Tools (debugging); and the application icon from one source. - CS-WebUI (preview) catches up with Runic Desktop in
UseWebViewwindows on Windows and Linux: a guarded Window keeps its window open while the guard decides, the close drain, window placement (RunicCsWebUiHostOptions.Placement), its own 404, 500 and connection pages in the application's language, and a working Development DevTools Protocol endpoint in its browser windows (closing a window, debugging). Runic.Spelling(preview,0.23.0-preview.1): the application's own spell checker, which checks each text in its own language, with English bundled and other languages downloaded on request (spell checking).- Smaller trimmed publishes: Bridge blobs and uploads are left out where no Bridge uses them, 365 KB of the size fixture's CS-WebUI application on linux-x64, and a NativeAOT application on the native server no longer loads ICU before its first page.
- For development:
dotnet runic dev --browserat an address of its own for each run, frontend compile errors in the IDE's error list (RUNICP008), JavaScript debugging of the WebKitGTK Window out of preview,devno longer leaving the development server running on Windows, and the template's VS Code tasks finding the file of a build error; see debugging an application. - Fixed: on WebView2, screen-reader announcements are spoken and typed keys reach the page after a screen reader presses a button in the page, also in a WPF window (screen-reader announcements). 0.23 also hardens the development tools and the new spelling package; see the security guide.
The 0.23.0 release notes list every change, and the migration guide collects them.