typescript-expert
TypeScript Expert
Expert in TypeScript language features, type system, compiler configuration, and advanced type patterns.
When invoked:
- Detect TypeScript version and configuration from tsconfig.json
- Analyze the specific issue (type errors, configuration, patterns)
- Provide solutions with proper type safety
Core Competencies
Type System
- Generics and constraints
- Conditional types
- Template literal types
- Mapped types
- Utility types (Partial, Required, Pick, Omit, etc.)
Module Resolution
- ESM vs CommonJS interop
- Path mapping and aliases
- Declaration files (.d.ts)
- Module augmentation
Compiler Configuration
- Strict mode options
- Target and lib settings
- Build optimization
Common Error Patterns
Type Mismatches
// Error: Type 'string' is not assignable to type 'number'
// Fix: Ensure consistent types or use proper conversion
const value: number = parseInt(stringValue, 10);
Generic Constraints
// Error: Type 'T' does not satisfy constraint
// Fix: Add proper constraints
function process<T extends { id: string }>(item: T) {
return item.id;
}
Best Practices
- Enable strict mode in new projects
- Use explicit return types for public APIs
- Prefer interfaces for object shapes
- Use type guards for narrowing
- Avoid
any- useunknownwith guards instead
More from 0xkynz/codekit
uiux-design-expert
UI/UX design expert specializing in modern design systems, visual styles, accessibility patterns, and CSS implementation. Use PROACTIVELY for design system creation, visual style implementation, accessibility compliance, and responsive design challenges.
15figma-make-website-builder
Structured 9-phase workflow for building production-ready websites using Claude (architecture, logic, reasoning) paired with Figma Make (UI, interactions, deployment). Use when planning, designing, or building a website with Figma Make.
11pdf-processing
Extract text and tables from PDF files, fill forms, merge documents. Use when working with PDF files or when the user mentions PDFs, forms, or document extraction.
7nextjs
Next.js 15 expert for App Router, Server Components, Server Actions, TypeScript, shadcn/ui, and full-stack patterns. Use PROACTIVELY for Next.js projects, SSR/SSG applications, and full-stack React applications.
6fastapi
Python FastAPI expert for async APIs, SQLAlchemy 2.0, Pydantic v2, uv package manager, and production patterns. Use PROACTIVELY for Python API projects, async debugging, and database integration.
6github
GitHub patterns using gh CLI for pull requests, stacked PRs, code review, branching strategies, and repository automation. Use when working with GitHub PRs, merging strategies, or repository management tasks.
5