Agent skill

TypeScript Pro

by Jeffallan in Jeffallan/claude-skills

Designs advanced TypeScript types: generics, conditional and mapped types, branded types, discriminated unions and type guards, with tsc checks and tRPC type safety.

MITAuto-check passedDevelopment

Install TypeScript Pro

skills CLI
$ npx skills add Jeffallan/claude-skills --skill typescript-pro -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install Jeffallan/claude-skills typescript-pro --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/Jeffallan/claude-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/typescript-pro .claude/skills/typescript-pro && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
typescript-pro
GitHub stars
12k
Used in
1 other repo
Token cost
~1.4k tokens
SKILL.md length
320 words
Files
6 (incl. references)
Skills in repo
58
Repo updated
First seen
Licence
MIT

At a glance

Designs advanced TypeScript types: generics, conditional and mapped types, branded types, discriminated unions and type guards, with tsc checks and tRPC type safety.

  • Works in 5 steps: Analyze type architecture - Review… → Design type-first APIs - Create branded… → Implement with type safety - Write type… → …
  • Modeling domain IDs with branded types
  • SKILL.md covers Core Workflow, Reference Guide, Code Examples and Constraints, plus 2 more sections
  • Calls tsc

What it does

The agent reviews tsconfig, type coverage and build performance, designs type-first APIs with branded types, generics and utility types, and implements type guards, discriminated unions and conditional types while running tsc --noEmit to catch errors. It then tunes the build with project references, incremental compilation and tree shaking, rechecks for zero errors, and confirms type coverage with a tool such as type-coverage and explicit return types on public APIs.

Reference files cover advanced types including template literals, type narrowing and assertion functions, utility types such as Partial, Pick, Omit and Record, tsconfig options and strict mode, and builder and factory patterns. Examples show a Brand type, a loading-success-error union, DeepReadonly and a recommended tsconfig.json. The rules call for strict mode with all compiler flags, the satisfies operator, declaration files for libraries and discriminated unions for state machines. The description also covers tRPC for end-to-end type safety and monorepo setup.

When your agent uses it

  • Modeling domain IDs with branded types
  • Writing conditional or mapped types and custom utility types
  • Replacing loose state objects with discriminated unions
  • Tightening tsconfig strictness and build speed with project references
  • Wiring tRPC for end-to-end type safety

Example prompts

  • “Create branded UserId and OrderId types so the two can no longer be mixed up.”
  • “Model the fetch state as a discriminated union and add a type guard for the error case.”
  • “Write a DeepReadonly utility type and use it on the config object.”
  • “Turn on strict mode in tsconfig.json and fix the new errors with tsc --noEmit.”

Requirements

  • TypeScript with `tsc`

Workflow steps

5 steps, taken from the first numbered list in SKILL.md.

  1. Analyze type architecture - Review tsconfig, type coverage, build performance
  2. Design type-first APIs - Create branded types, generics, utility types
  3. Implement with type safety - Write type guards, discriminated unions, conditional types; run tsc --noEmit to catch type errors before…
  4. Optimize build - Configure project references, incremental compilation, tree shaking; re-run tsc --noEmit to confirm zero errors after…
  5. Test types - Confirm type coverage with a tool like type-coverage; validate that all public APIs have explicit return types; iterate on…

What it can do on your machine

Read from SKILL.md and the folder at commit 1be15d8. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • tsc

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Links to these hosts (documentation or services it may open):

    • github.com
    • synergetic.solutions
    • jeffallan.github.io

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

TypeScript Pro loads about 1.4k tokens when it runs, and up to ~12k if it reads all its reference files. Until then it costs about 86 tokens; SKILL.md has 320 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~86
When it runs · the whole SKILL.md, loaded when a task matches
~1.4k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~12k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from Jeffallan/claude-skills at commit 1be15d8, republished under its MIT licence (© Jeffallan). 320 words, ~1,405 tokens.

Download SKILL.mdSave it as .claude/skills/typescript-pro/SKILL.md (or your agent's skills folder). This skill also uses 5 other files; get the full folder from GitHub.
name
typescript-pro
description
Implements advanced TypeScript type systems, creates custom type guards, utility types, and branded types, and configures tRPC for end-to-end type safety. Use when building TypeScript applications requiring advanced generics, conditional or mapped types, discriminated unions, monorepo setup, or full-stack type safety with tRPC.
license
MIT
metadata.author
https://github.com/Jeffallan
metadata.company
https://synergetic.solutions
metadata.version
1.1.0
metadata.domain
language
metadata.triggers
TypeScript, generics, type safety, conditional types, mapped types, tRPC, tsconfig, type guards, discriminated unions
metadata.role
specialist
metadata.scope
implementation
metadata.output-format
code
metadata.related-skills
fullstack-guardian, api-designer

TypeScript Pro

Core Workflow

  1. Analyze type architecture - Review tsconfig, type coverage, build performance
  2. Design type-first APIs - Create branded types, generics, utility types
  3. Implement with type safety - Write type guards, discriminated unions, conditional types; run tsc --noEmit to catch type errors before proceeding
  4. Optimize build - Configure project references, incremental compilation, tree shaking; re-run tsc --noEmit to confirm zero errors after changes
  5. Test types - Confirm type coverage with a tool like type-coverage; validate that all public APIs have explicit return types; iterate on steps 3–4 until all checks pass

Reference Guide

Load detailed guidance based on context:

TopicReferenceLoad When
Advanced Typesreferences/advanced-types.mdGenerics, conditional types, mapped types, template literals
Type Guardsreferences/type-guards.mdType narrowing, discriminated unions, assertion functions
Utility Typesreferences/utility-types.mdPartial, Pick, Omit, Record, custom utilities
Configurationreferences/configuration.mdtsconfig options, strict mode, project references
Patternsreferences/patterns.mdBuilder pattern, factory pattern, type-safe APIs

Code Examples

Branded Types
typescript
// Branded type for domain modeling
type Brand<T, B extends string> = T & { readonly __brand: B };
type UserId  = Brand<string, "UserId">;
type OrderId = Brand<number, "OrderId">;

const toUserId  = (id: string): UserId  => id as UserId;
const toOrderId = (id: number): OrderId => id as OrderId;

// Usage — prevents accidental id mix-ups at compile time
function getOrder(userId: UserId, orderId: OrderId) { /* ... */ }
Discriminated Unions & Type Guards
typescript
type LoadingState = { status: "loading" };
type SuccessState = { status: "success"; data: string[] };
type ErrorState   = { status: "error";   error: Error };
type RequestState = LoadingState | SuccessState | ErrorState;

// Type predicate guard
function isSuccess(state: RequestState): state is SuccessState {
  return state.status === "success";
}

// Exhaustive switch with discriminated union
function renderState(state: RequestState): string {
  switch (state.status) {
    case "loading": return "Loading…";
    case "success": return state.data.join(", ");
    case "error":   return state.error.message;
    default: {
      const _exhaustive: never = state;
      throw new Error(`Unhandled state: ${_exhaustive}`);
    }
  }
}
Custom Utility Types
typescript
// Deep readonly — immutable nested objects
type DeepReadonly<T> = {
  readonly [K in keyof T]: T[K] extends object ? DeepReadonly<T[K]> : T[K];
};

// Require exactly one of a set of keys
type RequireExactlyOne<T, Keys extends keyof T = keyof T> =
  Pick<T, Exclude<keyof T, Keys>> &
  { [K in Keys]-?: Required<Pick<T, K>> & Partial<Record<Exclude<Keys, K>, never>> }[Keys];
json
{
  "compilerOptions": {
    "target": "ES2022",
    "module": "NodeNext",
    "moduleResolution": "NodeNext",
    "strict": true,
    "noUncheckedIndexedAccess": true,
    "noImplicitOverride": true,
    "exactOptionalPropertyTypes": true,
    "isolatedModules": true,
    "declaration": true,
    "declarationMap": true,
    "incremental": true,
    "skipLibCheck": false
  }
}

Constraints

MUST DO
  • Enable strict mode with all compiler flags
  • Use type-first API design
  • Implement branded types for domain modeling
  • Use satisfies operator for type validation
  • Create discriminated unions for state machines
  • Use Annotated pattern with type predicates
  • Generate declaration files for libraries
  • Optimize for type inference
MUST NOT DO
  • Use explicit any without justification
  • Skip type coverage for public APIs
  • Mix type-only and value imports
  • Disable strict null checks
  • Use as assertions without necessity
  • Ignore compiler performance warnings
  • Skip declaration file generation
  • Use enums (prefer const objects with as const)

Output Templates

When implementing TypeScript features, provide:

  1. Type definitions (interfaces, types, generics)
  2. Implementation with type guards
  3. tsconfig configuration if needed
  4. Brief explanation of type design decisions

Knowledge Reference

TypeScript 5.0+, generics, conditional types, mapped types, template literal types, discriminated unions, type guards, branded types, tRPC, project references, incremental compilation, declaration files, const assertions, satisfies operator

Maintained by @jeffallan, Principal Consultant at Synergetic Solutions

Documentation

© Jeffallan, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 5 other files (references) in skills/typescript-pro of Jeffallan/claude-skills.

  • SKILL.md
  • references/advanced-types.md
  • references/configuration.md
  • references/patterns.md
  • references/type-guards.md
  • references/utility-types.md

Open the folder on GitHubat commit 1be15d8

Used in 1 other repository

We found 1 copy of this SKILL.md (exact, near-identical or edited) in other folders, from 1 other GitHub owner. This page covers the copy in Jeffallan/claude-skills, which our catalogue first saw on October 7, 2026.

Compare with similar skills

TypeScript Pro next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

TypeScript Pro compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
TypeScript Pro this skillJeffallan/claude-skills12k1 repos~1.4kAutomated safety check: PassMIT
Bumpy Add Changezap-studio/monorepo1721 repos~1.4kAutomated safety check: NotesMIT
Typescript Expertcin12211/orca-q22311 repos~3.7kAutomated safety check: PassMIT
TypeScript Monorepo Conventionspierrecomputer/pierre6.2k—~450Automated safety check: PassApache-2.0
Typescript Prozebbern/claude-code-guide4.6k—~958Automated safety check: PassMIT
Typescript Advanced Typesrolling-scopes/rsschool-app10k24 repos~4.2kAutomated safety check: PassMPL-2.0

Similar skills

  • Bumpy Add Change

    zap-studio/monorepo

    Create a bumpy bump file describing which packages changed and how, for version bumping and changelog generation.

    172 GitHub starsUsed in 1 repo~1.4k tokens
    DevelopmentAuto-check: notes
  • Typescript Expert

    cin12211/orca-q

    TypeScript and JavaScript expert with deep knowledge of type-level programming, performance optimization, monorepo management, migration strategies, and modern tooling.

    223 GitHub starsUsed in 11 repos~3.7k tokens
    DevelopmentAuto-check passed
  • TypeScript Monorepo Conventions

    pierrecomputer/pierre

    Conventions for adding packages and apps to a TypeScript monorepo: project references, moon tasks, workspace dependencies and published package exports.

    6.2k GitHub stars~450 tokensUpdated today
    DevelopmentAuto-check passed
  • Typescript Pro

    zebbern/claude-code-guide

    A skill your agent uses when building TypeScript applications requiring advanced type systems, generics, or full-stack type safety.

    4.6k GitHub stars~958 tokensUpdated today
    DevelopmentAuto-check passed
  • Typescript Advanced Types

    rolling-scopes/rsschool-app

    Master TypeScript's advanced type system including generics, conditional types, mapped types, template literals, and utility types for building type-safe applications.

    10k GitHub starsUsed in 24 repos~4.2k tokens
    DevelopmentAuto-check passed
  • Nx Import

    nrwl/nx

    Import, merge, or combine repositories into an Nx workspace using nx import.

    29k GitHub starsUsed in 5 repos~3.5k tokens
    DevelopmentAuto-check passed

More from Jeffallan/claude-skills

All 58 skills in this repo
  • API Designer

    Jeffallan/claude-skills

    Designs REST and GraphQL APIs from resource modeling to an OpenAPI 3.1 contract, with versioning, pagination and RFC 7807 error handling.

    12k GitHub starsUsed in 2 repos~2k tokens
    Auto-check passed
  • CLI Developer

    Jeffallan/claude-skills

    Walks through designing, building and polishing a command-line tool: user workflow and command hierarchy, implementation in commander, click, typer or cobra, completions and cross-platform testing.

    12k GitHub starsUsed in 1 repo~1.2k tokens
    Auto-check passed
  • Fine-Tuning Expert

    Jeffallan/claude-skills

    Guides LLM fine-tuning with LoRA and QLoRA through Hugging Face PEFT, from dataset validation and training checks to adapter merging, quantization and deployment.

    12k GitHub starsUsed in 1 repo~1.7k tokens
    Auto-check passed
  • GraphQL Architect

    Jeffallan/claude-skills

    Designs GraphQL schemas and Apollo Federation graphs, with DataLoader resolvers, subscriptions, query complexity limits and caching.

    12k GitHub starsUsed in 1 repo~1.3k tokens
    Auto-check passed
  • Kubernetes Specialist

    Jeffallan/claude-skills

    Creates and checks Kubernetes manifests, Helm charts, RBAC and network policies, and helps debug pod problems, with kubectl checks and rollback steps.

    12k GitHub starsUsed in 1 repo~2.1k tokens
    Auto-check passed
  • Laravel Specialist

    Jeffallan/claude-skills

    Builds Laravel 10+ applications with Eloquent models, Sanctum authentication, Horizon queues, API resources and Livewire components, tested with Pest or PHPUnit.

    12k GitHub starsUsed in 1 repo~2.1k tokens
    Auto-check passed

Works with

Categories

Questions about TypeScript Pro

What does TypeScript Pro do?

Designs advanced TypeScript types: generics, conditional and mapped types, branded types, discriminated unions and type guards, with tsc checks and tRPC type safety. The agent reviews tsconfig, type coverage and build performance, designs type-first APIs with branded types, generics and utility types, and implements type guards, discriminated unions and conditional types while running tsc --noEmit to catch errors. It then tunes the build with project references, incremental compilation and tree shaking, rechecks for zero errors, and confirms type coverage with a tool such as type-coverage and explicit return types on public APIs.

When should I use TypeScript Pro?

TypeScript Pro fits situations like: modeling domain IDs with branded types; writing conditional or mapped types and custom utility types; replacing loose state objects with discriminated unions; tightening tsconfig strictness and build speed with project references.

How do I install TypeScript Pro in Claude Code?

Run `npx skills add Jeffallan/claude-skills --skill typescript-pro -a claude-code`. Or copy the skill folder (skills/typescript-pro in Jeffallan/claude-skills) into .claude/skills/typescript-pro in your project. Claude Code loads it when a task matches its description.

How do I install TypeScript Pro in Codex?

Run `npx skills add Jeffallan/claude-skills --skill typescript-pro -a codex`. Or copy the skill folder (skills/typescript-pro in Jeffallan/claude-skills) into .agents/skills/typescript-pro in your project. Codex loads it when a task matches its description.

Can I use TypeScript Pro in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add Jeffallan/claude-skills --skill typescript-pro -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/typescript-pro, .gemini/skills/typescript-pro, .github/skills/typescript-pro and .opencode/skills/typescript-pro in your project.

What does TypeScript Pro need to run?

Going by SKILL.md and its folder, TypeScript Pro needs the command-line tools its instructions call (tsc). Our summary lists: TypeScript with `tsc`.

Does TypeScript Pro access the network?

SKILL.md names 3 domains. As links in the text: github.com, synergetic.solutions and jeffallan.github.io. This is read from the text; nothing was executed.

Is TypeScript Pro safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does TypeScript Pro use?

TypeScript Pro is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does TypeScript Pro use?

About 1.4k tokens (SKILL.md is roughly 5.6k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 11k tokens, read only when the agent opens those files.

What are the alternatives to TypeScript Pro?

Skills that share tags, products or a category with TypeScript Pro: Bumpy Add Change (zap-studio/monorepo, 172 stars), Typescript Expert (cin12211/orca-q, 223 stars), TypeScript Monorepo Conventions (pierrecomputer/pierre, 6.2k stars) and Typescript Pro (zebbern/claude-code-guide, 4.6k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains TypeScript Pro?

Jeffallan (a GitHub user) maintains it in Jeffallan/claude-skills, which has 11,754 GitHub stars. The repository holds 58 skills in this directory. The repository was last updated on October 3, 2026.

Source: Jeffallan/claude-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.