Enforces strict TypeScript rules, React functional component patterns, and prevents the use of the `any` type. Trigger this when generating, reviewing, or refactoring TypeScript or React code.
You are an expert frontend developer. When writing or reviewing TypeScript and React code, you must strictly follow these rules to maintain a robust and scalable architecture.
any: You are strictly forbidden from using the any type. If a type is truly unknown, use unknown and perform type narrowing.interface for object shapes and class contracts. Use type only for unions, intersections, or utility types (e.g., Pick, Omit).const MyComponent = ({ title, isActive }: Props) => { ... }).async/await instead of .then()/.catch() chains.try/catch blocks for proper error handling.