RxJS API Reference
Welcome to the comprehensive RxJS API reference. This documentation covers all creation operators, transformation operators, filtering operators, and utility functions available in RxJS.What is RxJS?
RxJS (Reactive Extensions for JavaScript) is a library for reactive programming using Observables, making it easier to compose asynchronous or callback-based code. It provides powerful operators for transforming, filtering, and combining streams of data.Core Concepts
Observable
An Observable is a collection of future values or events. It’s lazy - values are only computed when you subscribe to them.Observer
An Observer is a collection of callbacks that knows how to listen to values delivered by the Observable.Subscription
A Subscription represents the execution of an Observable and is primarily used for cancelling execution.Creation Operators
Creation operators are functions that create Observables from various sources. These are the building blocks for creating Observable streams.Common Creation Operators
of
Emits a sequence of values synchronously
from
Converts arrays, promises, or iterables to Observables
interval
Emits sequential numbers at specified intervals
timer
Emits after a delay, optionally repeating
fromEvent
Creates Observable from DOM or Node.js events
ajax
Creates Observable for AJAX requests
combineLatest
Combines latest values from multiple Observables
merge
Merges multiple Observables into one
All Creation Operators
- ajax - Create Observable for AJAX requests
- bindCallback - Convert callback API to Observable
- bindNodeCallback - Convert Node.js callback to Observable
- combineLatest - Combine latest values from Observables
- concat - Concatenate Observables sequentially
- defer - Create Observable lazily on subscription
- forkJoin - Wait for all Observables to complete
- from - Convert various sources to Observable
- fromEvent - Create from DOM or event emitter
- fromEventPattern - Create from arbitrary event API
- generate - Generate values using a loop
- interval - Emit numbers periodically
- merge - Merge multiple Observables concurrently
- of - Emit values as a sequence
- range - Emit a range of numbers
- throwError - Create Observable that errors
- timer - Emit after delay
- zip - Combine Observables by index
Quick Start Example
Type Safety
RxJS is written in TypeScript and provides full type safety for all operators.Next Steps
Explore Creation Operators
Learn about all the ways to create Observables
This API reference is based on RxJS v7+. Some operators may have different signatures in earlier versions.
