reactive-programming — Claude Code skill: RxJS streams
A skill for reactive streams in RxJS: observables, operators, backpressure. Useful when a project leans on async data and events.
npx skills add aj-geddes/useful-ai-prompts --skill reactive-programming -a claude-codeWhat reactive-programming does
The skill covers reactive patterns in RxJS: observables, Subject and BehaviorSubject, and operators such as map, filter, debounceTime, distinctUntilChanged and switchMap. It ships a short working example plus seven reference files under references/ — RxJS basics, search with debounce, state management, WebSocket with reconnection, combining multiple streams, backpressure handling and custom operators.
The agent pulls these in when you ask about a tangled async flow, live data updates, UI state or WebSocket and SSE handling. There is a practices section too: unsubscribe to avoid leaks, avoid nested subscriptions, handle errors, reach for shareReplay on expensive work. If your project already has its own stream layer, check the advice against it first — rules like never subscribing twice to the same observable will fight code built on manual subscription control.
Install commands differ per editor, but the content is the same across Claude, Codex, Cursor, GitHub Copilot, Gemini CLI and OpenCode.
What it helps with
- build a debounced search without extra requests
- keep UI state in a single stream
- reconnect a WebSocket after a drop
- merge data from several sources
- handle backpressure in a fast stream
Example prompts for the agent
- Rewrite this search with RxJS debounceTime and switchMap
- Create a cart state stream using BehaviorSubject
- Add WebSocket reconnection and error handling
How to install reactive-programming
1Skills CLI (Vercel)
npx skills add aj-geddes/useful-ai-prompts --skill reactive-programming -a claude-code2Manually: put the files in place
~/.claude/skills/reactive-programming/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/reactive-programming/
1Skills CLI (Vercel)
npx skills add aj-geddes/useful-ai-prompts --skill reactive-programming -a codex2Manually: put the files in place
.agents/skills/reactive-programming/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add aj-geddes/useful-ai-prompts --skill reactive-programming -a cursor2Manually: put the files in place
.cursor/skills/reactive-programming/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install aj-geddes/useful-ai-prompts reactive-programming2Manually: put the files in place
.github/skills/reactive-programming/SKILL.md1Skills CLI (Vercel)
npx skills add aj-geddes/useful-ai-prompts --skill reactive-programming -a gemini-cli2Platform CLI
gemini skills install https://github.com/aj-geddes/useful-ai-prompts --path skills/reactive-programmingManually: put the files in place
.devin/skills/reactive-programming/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add aj-geddes/useful-ai-prompts --skill reactive-programming -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
From the same set118
Similar
Nearby in Frontend and UI
Everything for Frontend and UI →Questions about reactive-programming
How do I install reactive-programming in Claude?
Run npx skills add aj-geddes/useful-ai-prompts --skill reactive-programming -a claude-code. The skill file lands at ~/.claude/skills/reactive-programming/SKILL.md.
What does reactive-programming do?
It gives the agent reference material on RxJS and reactive patterns: observables, operators, state management, WebSocket, backpressure. The agent draws on it when you ask for async stream code or a review of one.
Which platforms support the skill?
Claude, Codex, Cursor, GitHub Copilot, Gemini CLI and OpenCode. Each has its own install command; the skill content is identical.
Source text
SKILL.md · MIT
---
name: reactive-programming
description: >
Implement reactive programming patterns using RxJS, streams, observables, and
backpressure handling. Use when building event-driven UIs, handling async data
streams, or managing complex data flows.
---
# Reactive Programming
## Table of Contents
- [Overview](#overview)
- [When to Use](#when-to-use)
- [Quick Start](#quick-start)
- [Reference Guides](#reference-guides)
- [Best Practices](#best-practices)
## Overview
Build responsive applications using reactive streams and observables for handling asynchronous data flows.
## When to Use
- Complex async data flows
- Real-time data updates
- Event-driven architectures
- UI state management
- WebSocket/SSE handling
- Combining multiple data sources
## Quick Start
Minimal working example:
```typescript
import {
Observable,
Subject,
BehaviorSubject,
fromEvent,
interval,
} from "rxjs";
import {
map,
filter,
debounceTime,
distinctUntilChanged,
switchMap,
} from "rxjs/operators";
// Create observable from array
const numbers$ = new Observable<number>((subscriber) => {
subscriber.next(1);
subscriber.next(2);
subscriber.next(3);
subscriber.complete();
});
numbers$.subscribe({
next: (value) => console.log(value),
// ... (see reference guides for full implementation)
```
## Reference Guides
Detailed implementations in the `references/` directory:
| Guide | Contents |
|---|---|
| [RxJS Basics](references/rxjs-basics.md) | RxJS Basics |
| [Search with Debounce](references/search-with-debounce.md) | Search with Debounce |
| [State Management](references/state-management.md) | State Management |
| [WebSocket with Reconnection](references/websocket-with-reconnection.md) | WebSocket with Reconnection |
| [Combining Multiple Streams](references/combining-multiple-streams.md) | Combining Multiple Streams |
| [Backpressure Handling](references/backpressure-handling.md) | Backpressure Handling |
| [Custom Operators](references/custom-operators.md) | Custom Operators |
## Best Practices
### ✅ DO
- Unsubscribe to prevent memory leaks
- Use operators to transform data
- Handle errors properly
- Use shareReplay for expensive operations
- Combine streams when needed
- Test reactive code
### ❌ DON'T
- Subscribe multiple times to same observable
- Forget to unsubscribe
- Use nested subscriptions
- Ignore error handling
- Make observables stateful
© aj-geddes · MIT · aj-geddes/useful-ai-prompts