/migrate-to-typescript · Comandos slash para Claude Code | Prompt Studio
    1. Claude Code
    2. Comandos slash
    3. /migrate-to-typescript
    Claude Code · Comandos slashRefactor

    /migrate-to-typescript

    Migra un proyecto JavaScript a TypeScript.

    por davila7/claude-code-templates

    typescript

    Licencia: MITVer original

    Instalación

    npx claude-code-templates@latest --command setup/migrate-to-typescript

    Contenido

    Dónde va: .claude/commands/migrate-to-typescript.md

    ---
    allowed-tools: Read, Write, Edit, Bash
    argument-hint: "[migration-strategy] | --gradual | --complete | --strict | --incremental"
    description: Migrate JavaScript project to TypeScript with proper typing and tooling setup
    ---
    
    # Migrate to TypeScript
    
    Migrate JavaScript project to TypeScript with comprehensive type safety: **$ARGUMENTS**
    
    ## Current JavaScript State
    
    - Project structure: @package.json (analyze JS/TS mix and dependencies)
    - JavaScript files: !`find . -name "*.js" -not -path "./node_modules/*" | wc -l`
    - Existing TypeScript: !`find . -name "*.ts" -not -path "./node_modules/*" | wc -l`
    - Build system: @webpack.config.js or @vite.config.js or @rollup.config.js
    
    ## Task
    
    Systematically migrate JavaScript codebase to TypeScript with proper typing and tooling:
    
    **Migration Strategy**: Use $ARGUMENTS to specify gradual migration, complete conversion, strict mode, or incremental approach
    
    **Migration Process**:
    1. **Environment Setup** - TypeScript installation, tsconfig.json configuration, build tool integration
    2. **Type Definitions** - Install @types packages, create custom type declarations, define interfaces
    3. **File Migration** - Rename .js to .ts/.tsx, add type annotations, resolve compiler errors
    4. **Code Transformation** - Convert classes, functions, and modules with proper typing
    5. **Error Resolution** - Fix type mismatches, null/undefined handling, strict mode issues
    6. **Testing & Validation** - Update test files, configure type checking, validate type coverage
    
    **Advanced Features**: Generic types, mapped types, conditional types, module augmentation, and strict compiler settings.
    
    **Developer Experience**: Configure IDE integration, debugging, linting rules, and team onboarding.
    
    **Output**: Fully typed TypeScript codebase with strict type checking, comprehensive IntelliSense, and improved developer productivity.

    Más en Comandos slash

    • /commit

      Redacta un commit con Conventional Commits a partir de los cambios en stage.

    • /review

      Revisa el diff actual buscando bugs, casos borde y problemas de seguridad.

    • /tests

      Escribe tests para el archivo o función que indiques.

    • /changelog

      Genera las notas de versión desde el último tag.

    • /explain

      Explica cómo funciona un archivo o módulo, con un diagrama del flujo.

    • /cleanup

      Elimina imports, variables y código muerto sin cambiar el comportamiento.

    Ver todo en Comandos slash (717) →

    Tu colección definitiva de prompts de IA. Inspírate, explora ejemplos y crea con IA.

    Hubs principales

    • Prompts
    • Imágenes
    • Videos
    • Generar Videos
    • Plantillas
    • Animaciones
    • Precios
    • Conoce
    • Afiliado

    Explorar por tipo

    • Kits de componentes
    • Etiquetas de imagen
    • Etiquetas de video
    • Webs

    Temas populares

    • Música
    • Portafolio
    • Gaming
    • Viajes
    • Nano Banana Pro

    Legal

    • Términos de uso
    • Política de privacidad
    • Política de cookies
    • Política de licencias
    • Política de reembolsos
    • Términos del programa de afiliados
    • Términos de Crowdfunding

    Magzin LLC, 800 Third Avenue Associates, New York, NY, 10022, United States

    © 2026 Prompt Studio by Magzin. Todos los derechos reservados.