type-vs-interface
✓Use when defining object types. Use when choosing between type and interface. Use when extending types.
SKILL.md
Both type and interface can define object types, but they have different capabilities. Understanding these differences helps you choose the right tool and write consistent code.
| Object type (API response, props) | interface | | Union type | type | | Tuple type | type | | Function type | type | | Mapped type | type | | Primitive alias | type | | Library types meant to be extended | interface |
This is how TypeScript extends standard library types across ES versions.
Use when defining object types. Use when choosing between type and interface. Use when extending types. Source: marius-townhouse/effective-typescript-skills.
Facts (cite-ready)
Stable fields and commands for AI/search citations.
- Install command
npx skills add https://github.com/marius-townhouse/effective-typescript-skills --skill type-vs-interface- Category
- </>Dev Tools
- Verified
- ✓
- First Seen
- 2026-02-05
- Updated
- 2026-02-18
Quick answers
What is type-vs-interface?
Use when defining object types. Use when choosing between type and interface. Use when extending types. Source: marius-townhouse/effective-typescript-skills.
How do I install type-vs-interface?
Open your terminal or command line tool (Terminal, iTerm, Windows Terminal, etc.) Copy and run this command: npx skills add https://github.com/marius-townhouse/effective-typescript-skills --skill type-vs-interface Once installed, the skill will be automatically configured in your AI coding environment and ready to use in Claude Code or Cursor
Where is the source repository?
https://github.com/marius-townhouse/effective-typescript-skills
Details
- Category
- </>Dev Tools
- Source
- skills.sh
- First Seen
- 2026-02-05