typescript-wizard

typescript-wizard is a skill for Claude Code, Codex from FutureJJ/claude-skills. It costs 74 tokens per session (532 once invoked), scanned A, original, MIT.

Advanced TypeScript guidance for describing complex data shapes and rules that the compiler can check before the program runs.

In plain words
What is it for?
Designing generics, conditional and mapped types, template literal types, decorators, type inference, type narrowing, and discriminated unions.
Why use it?
It helps resolve difficult type errors and catch bugs without hiding them behind broad escape hatches such as any.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/futurejj/claude-skills/typescript-wizard
Any agent
npx skills add FutureJJ/claude-skills --skill typescript-wizard
Clone the repo
git clone --depth 1 https://github.com/FutureJJ/claude-skills

Made for: Claude Code, Codex.

Wrote 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.

agentmods badge for typescript-wizard

README.md
[![agentmods](https://agentmods.dev/badge/skills/futurejj/claude-skills/typescript-wizard.svg)](https://agentmods.dev/skills/futurejj/claude-skills/typescript-wizard)
Your own site
<a href="https://agentmods.dev/skills/futurejj/claude-skills/typescript-wizard"><img src="https://agentmods.dev/badge/skills/futurejj/claude-skills/typescript-wizard.svg" alt="Measured on agentmods" height="20"></a>
Per session 74 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 532 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00074 $0.00532
Opus 5 $0.00037 $0.00266
Sonnet 5 $0.00015 $0.00106
Haiku 4.5 $0.00007 $0.00053

Measured 5d ago against content hash 2b82406bb499, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

typescript-wizard 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 5d 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.

skills/typescript-wizard/SKILL.md · 41 lines

What it actually says

TypeScript Wizard

You are a TypeScript expert who thinks at the type level. Your goal is to write types that are precise enough to catch bugs at compile time but not so complex that they become unmaintainable.

Core Philosophy

  • Types should document intent. If a type needs a comment to explain it, the type is wrong.
  • Infer when possible. Let TypeScript figure out types from usage. Explicit annotations are for boundaries (function params, return types, exports).
  • Narrow, don't cast. Type guards and discriminated unions over as assertions.
  • Prefer unknown over any. unknown forces you to check; any silences the compiler.

Decision Framework

  1. Simple value? Use primitive types or literal types.
  2. Shape of an object? Use interface for public APIs (extendable), type for unions/intersections/computed types.
  3. Varies by input? Use generics with constraints.
  4. Conditional behavior? Use discriminated unions first, conditional types if needed.
  5. Repeating a pattern? Use mapped types or template literal types.

Anti-Patterns

  • Using any to "fix" type errors — you're hiding bugs, not fixing them
  • Overly complex utility types that nobody can read — simplicity > cleverness
  • as assertions instead of proper narrowing — runtime bugs waiting to happen
  • Enums for simple string unions — type Status = 'active' | 'inactive' is simpler and tree-shakeable
  • namespace in modern code — use ES modules instead

Reference Guide

Topic Reference Load When
Advanced generics references/generics.md Generic constraints, inference, patterns
Utility types references/utility-types.md Mapped types, conditional types, template literals
Type narrowing references/narrowing.md Type guards, discriminated unions, exhaustive checks
Configuration references/config.md tsconfig options, strict mode, project references
Files

What ships with it

4 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

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.

  1. 5d ago First seen · 41 lines · 74 tokens per session scan A 2b82406bb499

Subscribe to this mod's changes

typescript-wizard is a skill published in the GitHub repository FutureJJ/claude-skills (3 stars, last pushed 6mo ago), licensed MIT. It adds 74 tokens to every session and 532 once invoked, about $0.0004 per session on Opus 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-31.

Related

Other skills, from other repositories

typescript-best-practices

Use when reading or writing TypeScript or JavaScript files (.ts, .tsx, .js, tsconfig.json).

aiskillstore/marketplace · 30 tokens

neo-typescript

Use this skill when writing, reviewing, debugging, or architecting TypeScript code. Trigger for tsconfig/compiler options, strict mode, generics, conditional/mapped/template literal types, structural typing, ESM/CJS interop, decorators, library typing, or TypeScript runtime boundary issues.

Benknightdark/neo-skills · 63 tokens

typescript

Apply when writing TypeScript code. Strict types, discriminated unions, async patterns, and runtime safety.

sordi-ai/skill-everything · 23 tokens

swift-networking

Builds a protocol-based async/await networking layer with URLSession, testable abstractions, error handling, and mock support for Swift projects. Use when user says "add networking", "create an API layer", "fetch data from API", "build a network service", "add URLSession", "implement HTTP requests", "create a REST…

jeremieb/swift-unit-test-instructions · 82 tokens

swift-project-setup

Bootstraps a new Swift/SwiftUI/UIKit project with MVVM architecture, standard folder structure, testing targets, and CLAUDE.md configuration. Use when user says "create a new project", "setup a new app", "start a new iOS project", "scaffold a Swift project", "initialize an Xcode project", or "new SwiftUI app".

jeremieb/swift-unit-test-instructions · 80 tokens

vitest

Provides comprehensive guidance for Vitest testing framework including fast test execution, Vite integration, component testing, mocking, and configuration. Use when the user asks about Vitest, needs to write fast unit tests, test Vue/React components, or configure Vitest with Vite projects.

Zephyrex21/claude-skills-vetted · 59 tokens