{"id":18603029,"url":"https://github.com/devlooped/rxfree","last_synced_at":"2026-03-17T05:31:50.375Z","repository":{"id":40287675,"uuid":"197795096","full_name":"devlooped/RxFree","owner":"devlooped","description":"An ultra-lightweight Rx source-only nuget to avoid depending on the full System.Reactive for IObservable\u003cT\u003e producers","archived":false,"fork":false,"pushed_at":"2025-03-18T00:17:27.000Z","size":189,"stargazers_count":32,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-25T03:34:01.884Z","etag":null,"topics":["csharp","dotnet","reactive","rx"],"latest_commit_sha":null,"homepage":"https://clarius.org/RxFree","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/devlooped.png","metadata":{"files":{"readme":"readme.md","changelog":"changelog.md","contributing":null,"funding":null,"license":"license.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"devlooped"}},"created_at":"2019-07-19T15:10:34.000Z","updated_at":"2025-02-18T06:43:03.000Z","dependencies_parsed_at":"2024-01-24T18:46:18.271Z","dependency_job_id":"88d3d81c-2bc2-4bba-a2fe-64712cac9bb7","html_url":"https://github.com/devlooped/RxFree","commit_stats":null,"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devlooped%2FRxFree","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devlooped%2FRxFree/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devlooped%2FRxFree/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devlooped%2FRxFree/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/devlooped","download_url":"https://codeload.github.com/devlooped/RxFree/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248281400,"owners_count":21077423,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["csharp","dotnet","reactive","rx"],"created_at":"2024-11-07T02:13:19.602Z","updated_at":"2026-03-17T05:31:50.358Z","avatar_url":"https://github.com/devlooped.png","language":"C#","funding_links":["https://github.com/sponsors/devlooped","https://github.com/sponsors"],"categories":[],"sub_categories":[],"readme":"![Icon](https://raw.githubusercontent.com/devlooped/RxFree/main/assets/img/icon.png) RxFree\n============\n\n[![Version](https://img.shields.io/nuget/v/RxFree.svg?color=royalblue)](https://www.nuget.org/packages/RxFree)\n[![Downloads](https://img.shields.io/nuget/dt/RxFree.svg?color=darkmagenta)](https://www.nuget.org/packages/RxFree)\n[![License](https://img.shields.io/github/license/devlooped/RxFree.svg?color=blue)](https://github.com/devlooped/RxFree/blob/main/license.txt)\n[![Build](https://github.com/devlooped/RxFree/actions/workflows/build.yml/badge.svg?branch=main)](https://github.com/devlooped/RxFree/actions)\n\n\u003c!-- #content --\u003e\nAn ultra-lightweight Rx source-only (C#) nuget to avoid depending on the full \n[System.Reactive](https://www.nuget.org/packages/System.Reactive) for `IObservable\u003cT\u003e` \nproducers.\n\n100% dependency-free (source-based) support for library authors exposing IObservable\u0026lt;T\u0026gt; leveraging \nSubject\u0026lt;T\u0026gt;, CompositeDisposable, IObservable\u0026lt;T\u0026gt;.Subscribe extension method overloads,\nIObservable\u0026lt;T\u0026gt;.Select/Where/OfType LINQ operators, and others.\n\n# Usage\n\nAll of the documentation and samples for `Subject\u003cT\u003e` and the provided extension methods \n(i.e. `Subscribe` overloads) that are officially available for `System.Reactive` apply to \nthis project as well, since the implementations are heavily based on it (taking them to \nthe bare essentials for source-only inclusion, with `Subject\u003cT\u003e` being pretty much exactly \nthe same). \nFor example: [Using Subjects](https://docs.microsoft.com/en-us/previous-versions/dotnet/reactive-extensions/hh242970(v=vs.103)).\n\n```csharp\nusing System;\nusing System.Reactive.Subjects;\n\nvar subject = new Subject\u003cstring\u003e();\n\nsubject.Subscribe(x =\u003e Console.WriteLine($\"Got raw value {x}\"));\n\nsubject.Where(x =\u003e int.TryParse(x, out _))\n    .Select(x =\u003e int.Parse(x))\n    .Subscribe(x =\u003e Console.WriteLine($\"Got number {x} (squared is {x * x})\"));\n\nsubject.Where(x =\u003e bool.TryParse(x, out var value) \u0026\u0026 value)\n    .Subscribe(x =\u003e Console.WriteLine($\"Got a boolean True\"));\n\nwhile (Console.ReadLine() is var line \u0026\u0026 !string.IsNullOrEmpty(line))\n    subject.OnNext(line);\n```\n\nThis package is a drop-in replacement for `System.Reactive` if you are only using the \nmost common subset of features in it that are also provided in this project.\n\n# Why\n\nFor the most part, a producer needs the `Subject\u003cT\u003e` (read more about \n[using subjects](https://docs.microsoft.com/en-us/previous-versions/dotnet/reactive-extensions/hh242970(v=vs.103))) \nand maybe the `ObservableExtensions` that provide `Subscribe` overloads to provide \nlambdas instead of an `IObserver\u003cT\u003e`. Taking the somewhat large and heavy dependency \non the full [System.Reactive](https://www.nuget.org/packages/System.Reactive) to consume \njust the basics a reusable library needs is overkill in most cases.\n\nIn addition to `Subject\u003cT\u003e`, typical activities of a producer invole handling \ndisposables and potentially filtering/querying/converting other observables they \nconsume themselves in turn. For that purpose, the following simple features are \nincluded too: \n\n- `Subject\u003cT\u003e`: for producing observable sequences\n- `Disposable.Empty` and `Disposable.Create(Action)`\n- `CompositeDisposable`: allows disposing subscriptions as a group\n- Extension methods for `IObservable\u003cT\u003e`:\n   * `Subscribe` overloads receiving delegates for onNext, onError and onCompleted\n   * `Select`/`Where`/`OfType` LINQ operators\n\nThis is what this project provides at the moment, in source form, in your project, as internal \nclasses for your own implementation usage, with no external dependencies. They are not even \nvisible in the project since the package provides them automatically to the compiler, compiled \ninto your own assembly, and which you can fully debug as any other code in your project.\n\nAll types are included as `partial` classes, so you can easily add your own code to \nthem, and make them public if you need to.\n\n\u003c!-- #content --\u003e\n\n# Dogfooding\n\n[![CI Version](https://img.shields.io/endpoint?url=https://shields.kzu.app/vpre/RxFree/main\u0026label=nuget.ci\u0026color=brightgreen)](https://pkg.kzu.app/index.json)\n[![Build](https://github.com/devlooped/RxFree/actions/workflows/build.yml/badge.svg?branch=main)](https://github.com/devlooped/RxFree/actions)\n\nWe also produce CI packages from branches and pull requests so you can dogfood builds as quickly as they are produced. \n\nThe CI feed is `https://pkg.kzu.app/index.json`. \n\nThe versioning scheme for packages is:\n\n- PR builds: *42.42.42-pr*`[NUMBER]`\n- Branch builds: *42.42.42-*`[BRANCH]`.`[COMMITS]`\n\n\u003c!-- include https://github.com/devlooped/sponsors/raw/main/footer.md --\u003e\n# Sponsors \n\n\u003c!-- sponsors.md --\u003e\n[![Clarius Org](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/clarius.png \"Clarius Org\")](https://github.com/clarius)\n[![MFB Technologies, Inc.](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/MFB-Technologies-Inc.png \"MFB Technologies, Inc.\")](https://github.com/MFB-Technologies-Inc)\n[![Torutek](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/torutek-gh.png \"Torutek\")](https://github.com/torutek-gh)\n[![DRIVE.NET, Inc.](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/drivenet.png \"DRIVE.NET, Inc.\")](https://github.com/drivenet)\n[![Keith Pickford](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/Keflon.png \"Keith Pickford\")](https://github.com/Keflon)\n[![Thomas Bolon](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/tbolon.png \"Thomas Bolon\")](https://github.com/tbolon)\n[![Kori Francis](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/kfrancis.png \"Kori Francis\")](https://github.com/kfrancis)\n[![Toni Wenzel](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/twenzel.png \"Toni Wenzel\")](https://github.com/twenzel)\n[![Uno Platform](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/unoplatform.png \"Uno Platform\")](https://github.com/unoplatform)\n[![Reuben Swartz](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/rbnswartz.png \"Reuben Swartz\")](https://github.com/rbnswartz)\n[![Jacob Foshee](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/jfoshee.png \"Jacob Foshee\")](https://github.com/jfoshee)\n[![](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/Mrxx99.png \"\")](https://github.com/Mrxx99)\n[![Eric Johnson](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/eajhnsn1.png \"Eric Johnson\")](https://github.com/eajhnsn1)\n[![David JENNI](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/davidjenni.png \"David JENNI\")](https://github.com/davidjenni)\n[![Jonathan ](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/Jonathan-Hickey.png \"Jonathan \")](https://github.com/Jonathan-Hickey)\n[![Charley Wu](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/akunzai.png \"Charley Wu\")](https://github.com/akunzai)\n[![Ken Bonny](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/KenBonny.png \"Ken Bonny\")](https://github.com/KenBonny)\n[![Simon Cropp](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/SimonCropp.png \"Simon Cropp\")](https://github.com/SimonCropp)\n[![agileworks-eu](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/agileworks-eu.png \"agileworks-eu\")](https://github.com/agileworks-eu)\n[![sorahex](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/sorahex.png \"sorahex\")](https://github.com/sorahex)\n[![Zheyu Shen](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/arsdragonfly.png \"Zheyu Shen\")](https://github.com/arsdragonfly)\n[![Vezel](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/vezel-dev.png \"Vezel\")](https://github.com/vezel-dev)\n[![ChilliCream](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/ChilliCream.png \"ChilliCream\")](https://github.com/ChilliCream)\n[![4OTC](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/4OTC.png \"4OTC\")](https://github.com/4OTC)\n[![Vincent Limo](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/v-limo.png \"Vincent Limo\")](https://github.com/v-limo)\n[![Jordan S. Jones](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/jordansjones.png \"Jordan S. Jones\")](https://github.com/jordansjones)\n[![domischell](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/DominicSchell.png \"domischell\")](https://github.com/DominicSchell)\n[![Justin Wendlandt](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/jwendl.png \"Justin Wendlandt\")](https://github.com/jwendl)\n[![Adrian Alonso](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/adalon.png \"Adrian Alonso\")](https://github.com/adalon)\n[![Michael Hagedorn](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/Eule02.png \"Michael Hagedorn\")](https://github.com/Eule02)\n[![Matt Frear](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/mattfrear.png \"Matt Frear\")](https://github.com/mattfrear)\n\n\n\u003c!-- sponsors.md --\u003e\n\n[![Sponsor this project](https://raw.githubusercontent.com/devlooped/sponsors/main/sponsor.png \"Sponsor this project\")](https://github.com/sponsors/devlooped)\n\u0026nbsp;\n\n[Learn more about GitHub Sponsors](https://github.com/sponsors)\n\n\u003c!-- https://github.com/devlooped/sponsors/raw/main/footer.md --\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevlooped%2Frxfree","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdevlooped%2Frxfree","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevlooped%2Frxfree/lists"}