What problem does it solve?
This Skill provides a comprehensive set of universal coding standards, best practices, and patterns for TypeScript, JavaScript, React, and Node.js development, ensuring code consistency, readability, and maintainability across projects.
Core Features & Use Cases
- Code Quality Principles: Enforces principles like Readability First, KISS, DRY, and YAGNI.
- Language-Specific Standards: Detailed guidelines for TypeScript/JavaScript (naming, immutability, error handling, async/await, type safety) and React (component structure, custom hooks, state management, conditional rendering).
- API Design Standards: Covers REST conventions, response formats, and input validation using Zod.
- File Organization & Naming: Recommends project structure and file naming conventions.
- Comments & Documentation: Guidelines on when to comment and how to use JSDoc.
- Performance Best Practices: Covers memoization, lazy loading, and efficient database queries.
- Testing Standards: Emphasizes AAA pattern and descriptive test naming.
- Code Smell Detection: Identifies and advises on avoiding long functions, deep nesting, and magic numbers.
- Use Case: A new developer joins a project and needs to understand the established coding conventions. They can refer to this Skill to quickly get up to speed on the team's best practices for writing clean, efficient, and maintainable code.
Quick Start
Apply the coding standards to the provided TypeScript code snippet.