vue-best-practices

vue-best-practices is a skill for Claude Code from ejirocodes/agent-skills. It costs 159 tokens per session (947 once invoked), scanned A, original, MIT.

A practical reference for building, reviewing, and refactoring Vue 3 applications with TypeScript. Vue 3 is a JavaScript framework for user interfaces, and TypeScript adds checked types to JavaScript.

In plain words
What is it for?
Working with Vue components, props, Volar and vue-tsc settings, Pinia stores, Vue Router, component types, and TypeScript tooling.
Why use it?
It helps avoid common mistakes in components, editor tooling, module settings, hot reload, server rendering, and tests.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the vue-best-practices plugin — 1 skill shipped together

Good fit Working with Vue components, props, Volar and vue-tsc settings, Pinia stores, Vue Router, component types, and TypeScript tooling.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ejirocodes/agent-skills/vue-best-practices
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add ejirocodes/agent-skills --skill vue-best-practices
Clone the repo
git clone --depth 1 https://github.com/ejirocodes/agent-skills

Made for: Claude Code.

Or install vue-best-practices, the plugin that ships this one along with the rest of its 1 skill.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for vue-best-practices

README.md
[![agentmods](https://agentmods.dev/badge/skills/ejirocodes/agent-skills/vue-best-practices/github.svg)](https://agentmods.dev/skills/ejirocodes/agent-skills/vue-best-practices)
Your own site
<a href="https://agentmods.dev/skills/ejirocodes/agent-skills/vue-best-practices"><img src="https://agentmods.dev/badge/skills/ejirocodes/agent-skills/vue-best-practices/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for vue-best-practices

Your own site · 80×15
<a href="https://agentmods.dev/skills/ejirocodes/agent-skills/vue-best-practices"><img src="https://agentmods.dev/badge/skills/ejirocodes/agent-skills/vue-best-practices.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 159 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 947 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00159 $0.00947
Opus 5 $0.00079 $0.00474
Sonnet 5 $0.00032 $0.00189
Haiku 4.5 $0.00016 $0.00095

Measured 9d ago against content hash 346d30434b25, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

vue-best-practices scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

vue/skills/vue-best-practices/SKILL.md · 103 lines

How it starts

The opening of the file, as written. The whole thing — 103 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Vue 3 Best Practices

Quick Reference

Topic When to Use Reference
TypeScript Props extraction, generic components, useTemplateRef, JSDoc, reactive props destructure typescript.md
Volar IDE config, strictTemplates, CSS modules, directive comments, Volar 3.0 migration volar.md
Components defineModel, deep watch, onWatcherCleanup, useId, deferred teleport components.md
Tooling moduleResolution, HMR SSR, duplicate plugin detection tooling.md
Testing Pinia store mocking, setup stores, Vue Router typed params testing.md

Essential Patterns

Extract Component Props

import type { ComponentProps } from 'vue-component-type-helpers'
import MyButton from './MyButton.vue'

type Props = ComponentProps<typeof MyButton>

Reactive Props Destructure (Vue 3.5+)

<script setup lang="ts">
// Destructured props are reactive - preferred in Vue 3.5+
const { name, count = 0 } = defineProps<{ name: string; count?: number }>()
</script>

useTemplateRef (Vue 3.5+)

<script setup lang="ts">
import { useTemplateRef, onMounted } from 'vue'

const inputRef = useTemplateRef('input')  // Auto-typed
onMounted(() => inputRef.value?.focus())
</script>
<template><input ref="input" /></template>

onWatcherCleanup (Vue 3.5+)

import { watch, onWatcherCleanup } from 'vue'

watch(query, async (q) => {
  const controller = new AbortController()
  onWatcherCleanup(() => controller.abort())
  await fetch(`/api?q=${q}`, { signal: controller.signal })
})

defineModel with Required

// Returns Ref<Item> instead of Ref<Item | undefined>
const model = defineModel<Item>({ required: true })

Deep Watch with Numeric Depth

// Vue 3.5+ - watch array mutations without full traversal
watch(items, handler, { deep: 1 })

Read the full file on GitHub · 103 lines

Files

What ships with it

5 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 103 lines · 159 tokens per session scan A 346d30434b25

Subscribe to this mod's changes

vue-best-practices is a skill published in the GitHub repository ejirocodes/agent-skills (6 stars, last pushed 2mo ago), licensed MIT. It adds 159 tokens to every session and 947 once invoked, about $0.0008 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

nuxtjs-vue-typescript

Best practices for building Nuxt 3 and Vue 3 applications with TypeScript, the Composition API, and Tailwind CSS. Use when structuring Nuxt/Vue projects, writing composables, typing components and props, wiring up server routes and plugins, or optimizing Nuxt builds and Web Vitals.

Mindrally/skills · 70 tokens

inertia-rails-typescript

TypeScript type safety for Inertia Rails (React, Vue, Svelte): shared props, flash, and errors via InertiaConfig module augmentation in globals.d.ts. Use when setting up TypeScript types, configuring shared props typing, fixing TS2344 or TS2339 errors in Inertia components, or adding new shared data.

inertia-rails/skills · 74 tokens

nuxt-modules

Use when creating Nuxt modules: (1) Published npm modules (@nuxtjs/, nuxt-), (2) Local project modules (modules/ directory), (3) Runtime extensions (components, composables, plugins), (4) Server extensions (API routes, middleware), (5) Releasing/publishing modules to npm, (6) Setting up CI/CD workflows for modules.…

YuDefine/nuxt-supabase-starter · 105 tokens

vue-admin-skill

A planned Vue 3 and TypeScript skill for generating an administration interface: a back-office web application with pages, forms, tables, charts, navigation, and permissions. It describes a starter structure using Element Plus, Pinia, Vue Router, Vite, and related tools, but is not yet complete.

jiushiwon/wg-skills · 85 tokens

typescript-strict

Use when writing or reviewing TypeScript in Vue, Nuxt, Node, or shared TS utilities, fixing type errors, or deciding how to type API responses and composables.

pstuart/pstuart · 39 tokens

fec-vue3-project-standard

A Vue 3 and TypeScript project standard covering component boundaries, composables, routing, Pinia state, API layers, errors, styles, and project structure. Vue is a frontend framework, and composables are reusable functions for sharing component logic.

bovinphang/frontend-craft · 114 tokens