Add interactive buttons and forms to a Blazor static server-rendered page without setting up SignalR or WebAssembly.
Keep multiple components on the same page in sync using typed Reactive Signals when one component's state changes.
Build a shopping cart where adding a product automatically updates a cart total component elsewhere on the same page.
Replace full-page reload form submissions with lightweight server-roundtrip updates that preserve scroll and cursor position.
Requires .NET 8, 9, or 10 and existing familiarity with Blazor static server-side rendering.
ReactiveBlazor is a library for the .NET web framework Blazor that lets developers add interactive, stateful components to server-rendered pages without needing SignalR (a real-time connection protocol) or WebAssembly (code that runs inside the browser). Blazor's standard static server-side rendering mode does not support interactivity by itself, meaning buttons and form inputs do not respond to user actions without a full page reload. ReactiveBlazor fills that gap. When a user clicks a button or changes a form field on a ReactiveBlazor page, the browser sends a request to the server, the server updates the component's state and re-renders just that component, and the result is sent back and patched into the page without reloading. The patching uses a library called Idiomorph, which preserves scroll position, text cursor position, and CSS transitions during the update. The library handles a range of practical concerns automatically. Component state is encrypted and signed to prevent tampering, tokens expire after 24 hours by default, and anti-replay protection prevents a request from being submitted twice. CSRF protection is built in. Rapid interactions from the same component are queued to avoid race conditions. One notable feature is out-of-band updates via what the library calls Reactive Signals. One component can publish a typed signal (for example, a CartChanged signal when a product is added to a cart), and any other component on the same page that has declared interest in that signal is also re-rendered in the same server response. This keeps multiple components in sync without shared services or any custom JavaScript. The library supports .NET 8, 9, and 10, and bundles about 220 lines of vanilla JavaScript internally. Developers write no JavaScript of their own, all interaction logic lives in C#.
← im-ashar on gitmyhub — every repo by this author, as a profile.
Verify against the repo before relying on details.