excess-property-checking
Installation
SKILL.md
Distinguish Excess Property Checking from Type Checking
Overview
Object literals get special treatment: TypeScript flags unknown properties.
This catches typos and mistakes that structural typing would miss. But it only applies to object literals - understanding this distinction prevents confusion.
When to Use This Skill
- Assigning object literals to typed variables
- Confused why extra properties cause errors sometimes
- Error disappears when using intermediate variable
- Working with optional properties where typos are likely
- Designing interfaces with many optional fields