Turn a Kotlin list into a reactive stream with a single .toObservable() call.
Subscribe to an RxJava observable using Kotlin named arguments for clearer, less error-prone callback code.
Reduce RxJava boilerplate in an existing Kotlin Android or JVM project with a small drop-in library.
Must match RxKotlin version to your existing RxJava version (1.x, 2.x, or 3.x), project is not accepting new contributions.
RxKotlin is a small Kotlin library that adds convenience functions on top of RxJava, a popular Java library for reactive programming. Reactive programming is a style of writing code where the program responds to streams of data or events as they arrive, rather than fetching data at a specific moment and waiting for it. RxJava already works in Kotlin projects, but Kotlin has a feature called extension functions that allows adding new methods to existing classes, and RxKotlin uses this to make RxJava code more concise and natural-looking when written in Kotlin. As a practical example, RxKotlin lets you call .toObservable() directly on a Kotlin list or array to turn it into a reactive stream. It also provides subscribeBy(), which uses Kotlin named arguments to make it clearer what each callback is doing (onNext, onError, onComplete) rather than relying on positional parameters. These are small quality-of-life improvements rather than entirely new features. The library follows three major versions that correspond to the three major versions of RxJava: RxKotlin 3.x targets RxJava 3.x and is the active version, RxKotlin 2.x is in maintenance mode with bug fixes only, RxKotlin 1.x has reached end of life with no further support. Developers should pick the version that matches the RxJava version already in their project. Installation is through standard Java build tools: Maven, Gradle, or Ivy, with packages hosted on Maven Central. Snapshot builds from the development branch can also be pulled through JitPack. The project is part of the ReactiveX organization. As of October 2023, the README states the project is not accepting new contributions because of limited maintainer availability. The focus is on conservative additions that clearly reduce boilerplate rather than stylistic preferences.
← reactivex on gitmyhub — every repo by this author, as a profile.
Verify against the repo before relying on details.