Skip to content

Overview

Build reactive state for .NET: update a value, and the computations that depend on it update too.

  • Signals hold values you can read and write.
  • Memos derive values from tracked reads.
  • Effects run when a value they read changes.

A taste

open Ranvier

let graph = new Graph ()

let doubled =
    graph.Run (fun () ->
        let count = createSignal 1
        let doubled = createMemo (fun _ -> count.Value * 2)
        createEffect (fun () -> printfn "doubled = %d" doubled.Value)
        count.Value <- 5
        doubled)
doubled = 2
doubled = 10

What you get

Targets

net10.0, net8.0 and netstandard2.1 and Fable (JavaScript).

Guide

Status

Implementation status and planned features
AreaStatus
Core graph (signal, memo, effect, owners, batching)Implemented and tested.
Async and boundariesImplemented. A pending .Value read throws NotReadyException; TryValue reads without throwing.
Projections, lookups and selectorsImplemented, with factory map semantics. A node created inside a memo pulled by a projection row belongs to that memo.
Fable/JavaScriptImplemented and tested under Node.js; no package published yet. See Fable (JavaScript) target.
Collection combinators (Projection.filter, choose, map, mapWith, sortBy, groupBy)Implemented and tested, including pending and error behaviour; see Collections.
Editable values (createEditable, createDraft) and the MVU bridge (Mvu, in the Ranvier.Elmish package)Implemented and tested; see Editable values and forms and Migrating from Elmish.
Reusable lens and prism values for deep writesNot implemented; they wait on a need for reusable focus paths over collections.
Edit this page