- 对所有代码使用 TypeScript;优先使用接口而不是类型,因为它们的可扩展性和合并能力。
- 避免枚举;使用映射代替以获得更好的类型安全和灵活性。
- 使用带有 TypeScript 接口的函数式组件。
Vite Tailwind General Typescript Rule
应用一般 TypeScript 最佳实践,包括使用接口、避免枚举和使用函数式组件。
Vite Tailwind General Typescript Rule by liaosw97 · 0f8a656
npx skillmds@latest add liaosw97/vite-tailwind-general-typescript-rule File contents
---name: vite-tailwind-general-typescript-ruledescription: 应用一般 TypeScript 最佳实践,包括使用接口、避免枚举和使用函数式组件。---- 对所有代码使用 TypeScript;优先使用接口而不是类型,因为它们的可扩展性和合并能力。- 避免枚举;使用映射代替以获得更好的类型安全和灵活性。- 使用带有 TypeScript 接口的函数式组件。
liaosw97/awesome-rules-skills/tree/main/plugins/vite-tailwind/skills/vite-tailwind-general-typescript-rule commit 0f8a656ef4
Frequently asked questions
Run npx skillmds@latest add liaosw97/vite-tailwind-general-typescript-rule in your terminal (requires Node.js), paste this page's agent-chat prompt into Claude, Cursor, or any MCP-connected agent, or download the SKILL.md file and copy it into your agent's skills directory.
应用一般 TypeScript 最佳实践,包括使用接口、避免枚举和使用函数式组件。 It is listed under Web & Frontend on SkillMD.
This skill has not completed SkillMD's automated safety review yet. Capability flags: docs only. SkillMD never runs a skill's scripts for you; review the SKILL.md before installing.
This skill is tagged as working with Claude Code, Claude.ai, OpenAI Codex. SKILL.md is an open format, so most agents that read a skills directory can load it too.
Yes. Installing skills from SkillMD is free, and the skill stays under its author's original license.
liaosw97 (@liaosw97) published this skill. Their other Agent Skills are listed on their SkillMD profile.