vue-review
Comprehensive Vue.js code review for Composition API correctness, reactivity, composable patterns, template security, accessibility, and Vue-specific…
от jaswanthsanjay88★ 24 звезды на GitHub
Установить vue-review в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
Vue Code Review
This command invokes the vue-reviewer agent for Vue-specific code review. For pull requests touching .vue files or Vue-containing .ts/.js files, both vue-reviewer and typescript-reviewer should run — each owns a distinct lane.
What This Command Does
- Identify Vue Changes: Find modified
.vuefiles and Vue-related.ts/.jsfiles viagit diff - Run Lint: Execute
eslintwitheslint-plugin-vue - Typecheck: Run
vue-tsc --noEmitor the project's canonical typecheck command - Review Vue Lanes Only: Reactivity, composables, template security, accessibility, Vue-specific performance
- Generate Report: Categorize issues by severity (CRITICAL / HIGH / MEDIUM)
When to Use
Use /vue-review when:
- A PR or commit touches
.vuefiles - After writing or modifying Vue components, composables, or Pinia stores
- Before merging Vue code
- Auditing template security (
v-html, URL bindings) - Reviewing a new composable for correctness
- Auditing Vue Router guards and navigation
- Reviewing Nuxt server routes or SSR-specific code
For pure .ts/.js changes with no Vue imports, use /code-review (general) or invoke typescript-reviewer directly.
Scope vs /code-review and TypeScript Review
| Tool | Scope |
|---|---|
vue-reviewer (this command) |
Reactivity, composables, template security, a11y, Vue performance, Pinia/Router |
typescript-reviewer |
Generic TS/JS — any abuse, async correctness, Node security |
security-reviewer |
Project-wide security audit |
/code-review |
Generic uncommitted-changes or PR review |
On a .vue / Vue-related PR, invoke both vue-reviewer and typescript-reviewer. Findings from each are non-overlapping by design.
Review Categories
CRITICAL (Must Fix)
v-htmlwith unsanitized input:href/:srcwith unvalidated user URLs (javascript:,data:)- Secret in client bundle (
VITE_*, NuxtpublicruntimeConfig) - Server endpoint without input validation (Nuxt Nitro)
localStorage/sessionStoragefor session tokens- Destructuring reactive props in Vue < 3.5 (breaks reactivity)
reactive()object replacement (breaks watchers)- Watcher source tracking a ref object instead of
.value
HIGH (Should Fix)
- Composable with module-scope side effects
- Missing cleanup in composable (watcher, interval, listener)
v-forwithout:keyor withkey={index}v-if+v-foron same element- Props mutation
- Missing prop validation
- Route guard returning false without redirect
useRoute().paramsdestructured at top-level (snapshot)v-modelbound to computed without setter- Accessibility violations (missing labels, non-semantic interactive elements)
- Direct store property mutation outside actions
MEDIUM (Consider)
- Options API in new Vue 3 code
- Component over 300 lines
v-showwherev-ifis more appropriate (or vice versa)- Missing
:maxon<KeepAlive> - Missing
shallowReffor large replaced data - Custom validation instead of vetted form library
defineExposeexposing more than necessaryinheritAttrsnot disabled when usingv-bind="$attrs"
Automated Checks Run
# Lint (required)
npx eslint . --ext .vue,.ts,.js
# Vue-specific typecheck
vue-tsc --noEmit
# Targeted security rules
npx eslint . --rule 'vue/no-v-html: warn' \
--rule 'vue/no-template-target-blank: error'
# Supply-chain
npm audit
If eslint-plugin-vue or vue-tsc is not configured, the review will flag the gap as a HIGH config issue and continue.
Example Usage
User: /vue-review
Agent:
# Vue Code Review Report
## Files Reviewed
- src/components/UserCard.vue (modified)
- src/composables/useUser.ts (new)
- src/stores/useUserStore.ts (modified)
## Lint Results
PASS: eslint clean
PASS: vue-tsc clean
## Issues Found
[CRITICAL] Unsanitized v-html
File: src/components/UserCard.vue:15
Issue: User-controlled bio rendered as raw HTML via v-html.
Why: XSS via stored script tags in user input.
Fix: Sanitize with DOMPurify or render as text:
```vue
<script setup>
import DOMPurify from "dompurify";
const safeBio = computed(() => DOMPurify.sanitize(user.bio));
</script>
<template>
<div v-html="safeBio" />
</template>
```
[HIGH] Watcher in composable missing cleanup
File: src/composables/useUser.ts:22
Issue: `watch` callback fires fetch without AbortController; stale responses can overwrite newer data.
Fix: Use onCleanup to abort:
```ts
watch(userId, async (newId, _old, onCleanup) => {
const controller = new AbortController();
onCleanup(() => controller.abort());
const data = await fetch(`/api/users/${newId}`, { signal: controller.signal });
user.value = await data.json();
});
```
## Summary
- CRITICAL: 1
- HIGH: 1
- MEDIUM: 0
Recommendation: FAIL: Block merge until CRITICAL issue is fixed
Approval Criteria
| Status | Condition |
|---|---|
| PASS: Approve | No CRITICAL or HIGH issues |
| WARNING: Warning |
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл vue-review?
Comprehensive Vue.js code review for Composition API correctness, reactivity, composable patterns, template security, accessibility, and Vue-specific performance. Invokes the vue-reviewer agent (and typescript-reviewer alongside on .vue/.ts changes).
Как установить скилл vue-review?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл vue-review запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
mcp-builder
AnthropicGuide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
claude-api
AnthropicReference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
algorithmic-art
AnthropicCreating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
mcp-integration
AnthropicThis skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…