Skip to content

Samples to help learning ReactiveX, ReactiveUI, Avalonia UI

License

Notifications You must be signed in to change notification settings

genejo/ReactiveAvalonia

Repository files navigation

Reactive Avalonia

Purpose

Self-contained multiplatform samples to help understanding: ReactiveX, ReactiveUI, Avalonia UI. Featuring links to original reference material for each fresh chunk of code, e.g.

// https://reactiveui.net/docs/handbook/events/#how-do-i-convert-my-own-c-events-into-observables
Observable
    .FromEventPattern(wndMain, nameof(wndMain.Closing))
    .Subscribe(_ => Console.WriteLine("Main window closing..."))
    .DisposeWith(disposables);

Samples

Uses a finite observable stream of timer ticks. At each tick a new greeting is displayed. The sample can be a template for ReactiveUI + Avalonia applications.

Topics: View, ViewModel, (de)activation, timer, reactive property, type-safe bindings, WhenAnyValue, observable timer, UI thread and schedulers, window event.

Shows how to use async/await in a ReactiveUI context. It calls a dummy (but real) RESTful API.

Topics: command binding, ReactiveUI.Fody, Rx event pattern, WhenAnyObservable, async/await, timeout, json, Flurl.

Aims

About

Samples to help learning ReactiveX, ReactiveUI, Avalonia UI

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages