analyze_operators
Analyze RxJS code for creation functions, operators, performance patterns, and best practices
Run an RxJS snippet in a worker thread and get its emissions, timeline and memory back — or draw the marble diagram, or have the chain checked for leaks before it ships.
LABSCO SUMMARY
Reasoning about switchMap against mergeMap on paper is where RxJS bugs come from; running the snippet and reading the emissions with their timestamps settles it in one call. Pair that with the leak check, which is built around recognising the current cleanup idioms so it does not cry wolf on correct Angular or React code. The marble diagram is the part to hand to another person — it turns a timing argument into something you can look at.
A workbench for RxJS streams. Code is executed in an isolated worker and the emissions come back with timings, while the other tools read the same code statically for operator choices, subscription handling and lint rules.
Nothing to authorize; it runs over stdio as npx @shuji-bonji/rxjs-mcp, or installed globally. Execution happens locally in a worker thread on your machine, bounded by the timeout and emission count you pass. The execute call takes either an expression that evaluates to an Observable or a snippet ending in one — an explicit return always works. The lint tool is regex-based best-effort analysis rather than a real ESLint run. It is a community project, not affiliated with the RxJS team. MIT.
One command — npx @shuji-bonji/rxjs-mcp
USE CASES
Run the snippet in isolation and read the emissions with their timings, capped at a number of values so an infinite stream still returns.
Turn the timed events into an ASCII marble diagram, with the scale and duration set so the interesting part is visible.
Analyse the code for missing teardown and uncompleted subjects, with the component lifecycle taken into account so idiomatic cleanup is not flagged.
Lint against the recommended or strict rule set for the framework in question, and read the operator analysis for the chains it flags.
Ask for the pattern for the use case — retrying HTTP, debounced search, polling with backoff, reconnecting sockets — in the framework you are working in.
Counted once with only startup setup. Other versions, modes or optional credentials may expose a different list.
analyze_operatorsAnalyze RxJS code for creation functions, operators, performance patterns, and best practices
detect_memory_leakAnalyze RxJS code for potential memory leaks and subscription management issues. Recognizes modern auto-cleanup patterns (takeUntilDestroyed, async pipe, useEffect cleanup, onUnmounted) to avoid false positives.
execute_streamExecute RxJS code in an isolated environment and capture the stream emissions, timeline, and performance metrics. Code runs in a separate worker thread for security.
generate_marbleGenerate ASCII marble diagrams to visualize RxJS stream emissions over time
lint_rxjsLint RxJS code snippets for common issues and best practices (regex-based best-effort analysis, no ESLint runtime required). Based on eslint-plugin-rxjs-x rules. Checks for nested subscribes, memory leaks, deprecated patterns, and more. Rules marked as type-info-required use heuristics and may have false positives/negatives. Supports framework-specific rules for Angular, React, and Vue.
suggest_patternSuggest RxJS patterns and best practices for common use cases
BEFORE YOU INSTALL
6 tools when we connected.
npx on PATH
All 3 documented clients run the server on your machine.
CONTEXT COST
Rated by the size of the 6 tool definitions that ride along on every turn, not by how many there are
INSTALLATION
npx @shuji-bonji/rxjs-mcp{
"mcpServers": {
"rxjs": {
"command": "npx",
"args": [
"@shuji-bonji/rxjs-mcp"
]
}
}
}{
"servers": {
"rxjs": {
"command": "npx",
"args": [
"@shuji-bonji/rxjs-mcp"
]
}
}
}