What problem does it solve?
This Skill addresses common pitfalls in TypeScript development that lead to runtime errors or broken builds, such as unsafe type assertions, poor error handling, insecure environment variable access, and unused imports.
Core Features & Use Cases
- Type Safety: Enforces strict typing for parsed JSON and API responses using Zod schemas.
- Robust Error Handling: Implements a typed
tryCatch utility for predictable error management.
- Secure Environment Variables: Integrates with T3 Env for validated, type-safe access to environment variables.
- Clean Imports: Utilizes
eslint-plugin-unused-imports to eliminate unused dependencies.
- Use Case: When refactoring a legacy JavaScript project to TypeScript, this Skill ensures that all external data is validated, errors are caught gracefully, and the codebase remains clean and maintainable.
Quick Start
Use the maintaining-quality skill to refactor the provided TypeScript code snippet to include Zod validation for JSON parsing.