Getting it into your agent
It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.
git clone --depth 1 https://github.com/blader/Claudeceptionnpx agentmods add skills/blader/claudeception/typescript-circular-dependencyWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/blader/claudeception/typescript-circular-dependency)<a href="https://agentmods.dev/skills/blader/claudeception/typescript-circular-dependency"><img src="https://agentmods.dev/badge/skills/blader/claudeception/typescript-circular-dependency/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/blader/claudeception/typescript-circular-dependency"><img src="https://agentmods.dev/badge/skills/blader/claudeception/typescript-circular-dependency.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector warn
SkillSpector: 1 finding, up to medium
These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →
- medium MCP Rug Pull · line 68 npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.Fix: Pin the version: npx @scope/[email protected]
What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00088 | $0.01320 |
| Opus 5.5 | $0.00035 | $0.00528 |
| Sonnet 5.5 | $0.00018 | $0.00264 |
| Haiku 4.5 | $0.00009 | $0.00132 |
Grade A, and why
typescript-circular-dependency scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
Copies of this mod
1 near-identical copy found in the catalogue:
- typescript-circular-dependency — 100% identical, 0 lines differ
How it starts
The opening of the file, as written. The whole thing — 238 lines — stays where its author put it; the contents beside it link to each section on GitHub.
TypeScript Circular Dependency Detection and Resolution
Problem
Circular dependencies occur when module A imports from module B, which imports
(directly or indirectly) from module A. TypeScript compiles successfully, but at
runtime, one of the imports evaluates to undefined because the module hasn't
finished initializing yet.
Context / Trigger Conditions
Common error messages:
ReferenceError: Cannot access 'UserService' before initialization
TypeError: Cannot read properties of undefined (reading 'create')
TypeError: (0 , _service.doSomething) is not a function
Symptoms that suggest circular imports:
- Import is
undefinedeven though the export exists - Error only appears at runtime, not during TypeScript compilation
- Moving an import statement changes which import is undefined
- Tests fail but the app works (or vice versa)
- Adding
console.logat the top of a file changes behavior
Solution
Step 1: Detect the Cycle
Use a tool to visualize dependencies:
# Install madge
npm install -g madge
# Find circular dependencies
madge --circular --extensions ts,tsx src/
# Generate visual graph
madge --circular --image graph.svg src/
Or use the TypeScript compiler:
# Check for cycles (requires tsconfig setting)
npx tsc --listFiles | head -50
Step 2: Identify the Pattern
Common circular dependency patterns:
Pattern A: Service-to-Service
services/userService.ts → services/orderService.ts → services/userService.ts
Pattern B: Type imports
types/user.ts → types/order.ts → types/user.ts
Pattern C: Index barrel files
components/index.ts → components/Button.tsx → components/index.ts
Step 3: Resolution Strategies
Strategy 1: Extract Shared Dependencies
Before:
// userService.ts
import { OrderService } from './orderService';
export class UserService { ... }
// orderService.ts
import { UserService } from './userService';
export class OrderService { ... }
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 3mo ago First seen · 238 lines · 88 tokens per session scan A b05ad87becdc
typescript-circular-dependency is a skill published in the GitHub repository blader/Claudeception (2,471 stars, last pushed 9mo ago), licensed MIT. It adds 88 tokens to every session and 1,320 once invoked, about $0.0004 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
typescript-circular-dependency compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| typescript-circular-dependencyblader/Claudeception | Skill | 2.5k | 9mo ago | MIT | A | 88 | Claude Code, Codex |
| cli-wiringgithub/gh-aw | Skill | 5.7k | today | MIT | A | 0 | Claude Code, Codex |
| agents-sdk-typescript-debuggingmicrosoft/Agents | Skill | 1.1k | 5d ago | MIT | A | 125 | Claude Code |
| configkubb-labs/kubb | Skill | 1.9k | today | MIT | A | 49 | Claude Code |
| angularericrisco/rsc-harness | Skill | 682 | 5d ago | MIT | A | 89 | Claude Code, Codex |
| node-modules-inspectorantfu/node-modules-inspector | Skill | 3.0k | 2mo ago | MIT | A | 156 | Claude Code, Codex |
| agent-inspectrajudandigam/agent-inspect | Skill | 214 | today | MIT | A | 52 | Claude Code, Codex |