vuejs-typescript-best-practices — Claude Code skill: Vue and TS rules
Hands your agent a rulebook for Vue.js and TypeScript: Composition API, Pinia, VueUse, Tailwind, plus Vite build tuning. Useful once a Vue codebase outgrows one person's style.
npx skills add Mindrally/skills --skill vuejs-typescript-best-practices -a claude-codeWhat vuejs-typescript-best-practices does
The skill frames the assistant as an expert in TypeScript, Node.js, Vite, Vue Router, Pinia, VueUse, Headless UI, Element Plus and Tailwind. It does not write code on its own; it sets the constraints your agent works inside when it edits files.
What's in it: functional and declarative patterns instead of classes, interfaces over types, maps instead of enums. Directories use lowercase with dashes, functions get named exports, pure functions use the function keyword. Every component goes through the Composition API with script setup.
A separate section covers performance. Wrap async components in Suspense with a fallback UI, load non-critical components dynamically, serve images as WebP with size data and lazy loading, and split chunks during the Vite build. For Web Vitals the skill points at Lighthouse or WebPageTest. Worth knowing before you install: these are conventions, not a linter, so when your existing code disagrees the agent will side with the skill.
What it helps with
- unify code style across a growing Vue project
- migrate components to the Composition API and script setup
- drop enums from TypeScript in favour of maps
- set up code splitting in the Vite build
- improve Web Vitals and lazy-load images
Example prompts for the agent
- Rewrite this component with the Composition API, script setup and TypeScript
- Review the folder structure under src and rename things per the skill's conventions
- Split the Vite build into chunks and show me the config diff
How to install vuejs-typescript-best-practices
1Skills CLI (Vercel)
npx skills add Mindrally/skills --skill vuejs-typescript-best-practices -a claude-code2Manually: put the files in place
~/.claude/skills/vuejs-typescript-best-practices/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/vuejs-typescript-best-practices/
1Skills CLI (Vercel)
npx skills add Mindrally/skills --skill vuejs-typescript-best-practices -a codex2Manually: put the files in place
.agents/skills/vuejs-typescript-best-practices/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add Mindrally/skills --skill vuejs-typescript-best-practices -a cursor2Manually: put the files in place
.cursor/skills/vuejs-typescript-best-practices/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install Mindrally/skills vuejs-typescript-best-practices2Manually: put the files in place
.github/skills/vuejs-typescript-best-practices/SKILL.md1Skills CLI (Vercel)
npx skills add Mindrally/skills --skill vuejs-typescript-best-practices -a gemini-cli2Platform CLI
gemini skills install https://github.com/Mindrally/skills --path vuejs-typescript-best-practicesManually: put the files in place
.devin/skills/vuejs-typescript-best-practices/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add Mindrally/skills --skill vuejs-typescript-best-practices -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about vuejs-typescript-best-practices
How do I install vuejs-typescript-best-practices in Claude?
Run npx skills add Mindrally/skills --skill vuejs-typescript-best-practices -a claude-code. The skill file then lands at ~/.claude/skills/vuejs-typescript-best-practices/SKILL.md.
What does vuejs-typescript-best-practices do?
It gives your agent conventions for Vue.js and TypeScript work: code style, naming, type usage, Composition API components, and performance and build optimisation.
Which tools does this skill cover?
TypeScript, Node.js, Vite, Vue Router, Pinia, VueUse, Headless UI, Element Plus and Tailwind CSS. Styling and components lean on Tailwind with a mobile-first approach.
Source text
SKILL.md · Apache-2.0
--- name: vuejs-typescript-best-practices description: Vue.js and TypeScript best practices for building performant applications with Vite, Pinia, VueUse, and Tailwind CSS. metadata: maintainer: Mindrally source: https://github.com/Mindrally/skills --- # Vue.js TypeScript Best Practices You are an expert in TypeScript, Node.js, Vite, Vue.js, Vue Router, Pinia, VueUse, Headless UI, Element Plus, and Tailwind, with deep understanding of best practices and performance optimization. ## Code Style and Structure - Write concise, maintainable, and technically accurate TypeScript code with relevant examples - Use functional and declarative programming patterns; avoid classes - Favor iteration and modularization to adhere to DRY principles and avoid code duplication - Use descriptive variable names with auxiliary verbs (e.g., isLoading, hasError) - Organize files systematically: each file should contain only related content, such as exported components, subcomponents, helpers, static content, and types ## Naming Conventions - Use lowercase with dashes for directories (e.g., components/auth-wizard) - Favor named exports for functions ## TypeScript Usage - Use TypeScript for all code; prefer interfaces over types for their extendability and ability to merge - Avoid enums; use maps instead for better type safety and flexibility - Use functional components with TypeScript interfaces ## Syntax and Formatting - Use the "function" keyword for pure functions to benefit from hoisting and clarity - Always use the Vue Composition API script setup style ## UI and Styling - Use Headless UI, Element Plus, and Tailwind for components and styling - Implement responsive design with Tailwind CSS; use a mobile-first approach ## Performance Optimization - Leverage VueUse functions where applicable to enhance reactivity and performance - Wrap asynchronous components in Suspense with a fallback UI - Use dynamic loading for non-critical components - Optimize images: use WebP format, include size data, implement lazy loading - Implement an optimized chunking strategy during the Vite build process, such as code splitting, to generate smaller bundle sizes ## Key Conventions - Optimize Web Vitals (LCP, CLS, FID) using tools like Lighthouse or WebPageTest
© Mindrally · Apache-2.0 · Mindrally/skills