typescript-master

Diagnoses TypeScript errors and recommends fixes and compiler settings for optimal code health.

Updated Apr 16, 2026
One-click install
npx skills add https://github.com/duylinhdang1998/claude-template-agent --skill typescript-master-duylinhdang1998
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: typescript-master
Source: https://github.com/duylinhdang1998/claude-template-agent/tree/main/plugins/vfm-agent-company/skills/typescript-master
Command: npx skills add https://github.com/duylinhdang1998/claude-template-agent --skill typescript-master-duylinhdang1998

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Managing and scaling complex TypeScript type systems is error-prone and time-consuming, leading to confusing compiler errors, fragile APIs, and runtime bugs; this skill provides focused expertise to design, refactor, and harden types so teams can move faster with confidence.

Core Features & Use Cases

  • Advanced type design: help create and document robust generics, discriminated unions, conditional and mapped types for reusable libraries.
  • Type error resolution: diagnose compiler errors, propose minimal reproducible fixes, and explain root causes clearly.
  • Configuration & tooling: recommend tsconfig and compiler options for strict mode, module resolution, and build targets.
  • Migration & refactor: guide incremental JS→TS migrations, conversions of implicit any to strict types, and safe API surface changes.
  • Framework patterns: apply TypeScript best practices for React props, hooks, Node/Express handlers, and typed async code.

Quick Start

Use the typescript-master skill to analyze a TypeScript error or code snippet and return a minimal reproducible fix, an explanation of the issue, and recommended tsconfig/compiler settings.

Frequently Asked Questions about typescript-master

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I fix complex TypeScript compiler errors and strict type safety issues?

To fix TypeScript compiler errors, you need to diagnose the root cause and apply minimal reproducible code changes. This involves resolving type inference issues, correcting generic constraints, and tuning tsconfig strict mode settings to eliminate runtime type defects.

What is the best way to refactor implicit any types during a JavaScript to TypeScript migration?

Refactoring implicit any types during a JS to TS migration requires incremental type assignments and safe API surface changes. Converting implicit any to strict types ensures type safety while maintaining functionality, guided by recommended compiler options and actionable tests.

How do I design advanced TypeScript generics and discriminated unions for a reusable library?

Designing advanced TypeScript generics and discriminated unions involves creating robust conditional and mapped types with correct constraints. This improves type inference and ensures reusable library APIs are type-safe and clearly documented for scalable development.

Can I apply TypeScript best practices to React props and Node Express handlers?

You can apply TypeScript best practices to React props, hooks, and Node Express handlers by implementing typed async code and strict type signatures. This enforces type safety across framework codebases and reduces runtime defects in component and API logic.

What tsconfig compiler options should I use for strict mode and module resolution?

For strict mode and module resolution, your tsconfig should enable strict compiler options and appropriate build targets. Tuning these settings enforces type safety, ensures correct module resolution, and minimizes runtime type errors across large-scale TypeScript projects.

Why does TypeScript type inference fail with complex conditional types and how can I resolve it?

TypeScript type inference can fail with complex conditional types due to incorrect generic constraints or unresolved mapped types. Resolving this requires adjusting type constraints and applying actionable code changes to satisfy the compiler and ensure strict type safety.