{"id":10416,"library":"rxjs","title":"RxJS: Reactive Extensions For JavaScript","description":"RxJS (Reactive Extensions for JavaScript) is a library for reactive programming using Observables, making it easier to compose asynchronous or callback-based code sequences. The current stable version is 7.8.2, with an active roadmap towards version 8, including regular alpha releases and maintenance updates.","status":"active","version":"7.8.2","language":"javascript","source_language":"en","source_url":"https://github.com/reactivex/rxjs","tags":["javascript","Rx","RxJS","ReactiveX","ReactiveExtensions","Streams","Observables","Observable","Stream","typescript"],"install":[{"cmd":"npm install rxjs","lang":"bash","label":"npm"},{"cmd":"yarn add rxjs","lang":"bash","label":"yarn"},{"cmd":"pnpm add rxjs","lang":"bash","label":"pnpm"}],"dependencies":[],"imports":[{"note":"For RxJS versions 7.2 and above, all creation functions and operators are imported directly from 'rxjs'. For versions below 7.2, operators were imported from 'rxjs/operators'.","wrong":"import { filter, map } from 'rxjs/operators';","symbol":"range, filter, map","correct":"import { range, filter, map } from 'rxjs';"}],"quickstart":{"code":"import { range, filter, map } from 'rxjs';\n\nrange(1, 200)\n  .pipe(\n    filter(x => x % 2 === 1),\n    map(x => x + x)\n  )\n  .subscribe(x => console.log(x));","lang":"typescript","description":"Demonstrates creating an Observable from a range, applying `filter` and `map` operators using `.pipe()`, and subscribing to log the results."},"warnings":[{"fix":"Do not rely on `Symbol.observable` being exported for custom interop. Use `Symbol.observable` directly from `Symbol` if needed for custom implementations.","message":"The `Symbol.observable` export has been removed.","severity":"breaking","affected_versions":">=8.0.0-alpha.13"},{"fix":"Instantiate `Subject` directly using `new Subject()` instead of calling `Subject.create()`.","message":"The deprecated `Subject.create` method has been removed.","severity":"breaking","affected_versions":">=8.0.0-alpha.13"},{"fix":"Update code that relies on `WebSocketSubject` having all the methods and properties of a `Subject`.","message":"`WebSocketSubject` no longer extends `Subject`.","severity":"breaking","affected_versions":">=8.0.0-alpha.13"},{"fix":"Import all operators directly from `'rxjs'` (e.g., `import { map } from 'rxjs';`). Using `import { map } from 'rxjs/operators';` is for versions below 7.2 and may cause issues or larger bundle sizes in newer versions.","message":"Operator import paths changed in RxJS 7.2.","severity":"gotcha","affected_versions":">=7.2"}],"env_vars":null,"last_verified":"2026-04-18T00:00:00.000Z","next_check":"2026-07-17T00:00:00.000Z","problems":[{"fix":"Import operators directly from 'rxjs' instead, e.g., `import { map } from 'rxjs';`.","cause":"Attempting to import operators from 'rxjs/operators' in RxJS version 7.2 or later.","error":"Module not found: Can't resolve 'rxjs/operators'"},{"fix":"Instantiate `Subject` directly using its constructor: `const subject = new Subject();`.","cause":"Calling the `create` static method on `Subject` in RxJS v8 or later.","error":"TypeError: Subject.create is not a function"},{"fix":"Ensure `observable.subscribe()` is called to activate the Observable and start emitting values.","cause":"An Observable was created but its `subscribe()` method was not called, preventing it from executing.","error":"TypeError: Cannot read properties of undefined (reading 'subscribe')"},{"fix":"Wrap your operators within a `.pipe()` call: `observable.pipe(operator1(), operator2()).subscribe(...)`.","cause":"Attempting to use an operator directly on an Observable instance without using the `.pipe()` method.","error":"Property 'pipe' does not exist on type 'Observable<any>'"}],"ecosystem":"npm"}