Avoid common Vue mistakes — reactivity traps, ref vs reactive, computed timing, and Composition API pitfalls.
数据来源:ClawHub。 在 ClawSkills 查看
选择你使用的 Agent
方法一:命令行安装(推荐)
推荐(无需提前安装 clawhub)
npx clawhub@latest --dir ~/.claude/skills install vue或使用 clawhub CLI(需提前安装)
clawhub --dir ~/.claude/skills install vue⚠️ 需要 Node.js 18+,没有 Node?请使用下方方法二直接下载 ZIP。 安装 Node.js →
方法二:手动下载安装(无需 Node)
下载 ZIP,解压后将文件夹放到以下路径,重启 Agent 即可:
安装路径
~/.claude/skills/vue/💡解压后将文件夹放到上方路径,重启 Agent 即可生效
--- name: Vue slug: vue version: 1.0.1 description: Build Vue 3 applications with Composition API, proper reactivity patterns, and production-ready components. metadata: {"clawdbot":{"emoji":"💚","requires":{"bins":["node"]},"os":["linux","darwin","win32"]}} ---
User needs Vue expertise — from Composition API patterns to production optimization. Agent handles reactivity, component design, state management, and performance.
| Topic | File | |-------|------| | Reactivity patterns | reactivity.md | | Component patterns | components.md | | Composables design | composables.md | | Performance optimization | performance.md |
is the recommended syntax—cleaner and better performanceref for primitives—access with .value in script, auto-unwrapped in templatereactive can't reassign whole object—state = {...} breaks reactivityreactive loses reactivity—use toRefs(state) to preservearr[0] = x works, unlike Vue 2reactive({count: ref(0)}).count is number, not refcomputed for derived state—cached, recalculates only when dependencies changewatch for side effects—when you need to DO something in response to changescomputed should be pure—no side effects, no asyncwatchEffect for immediate reaction with auto-tracked dependenciesdeep: true—or watch a getter functionwatch is lazy by default—use immediate: true for initial runwatch(source, (newVal, oldVal) => {})watchEffect can't access old value—use watch if you need old/new comparisonconst stop = watch(...); stop()defineProps for type-safe props—defineProps<{ msg: string }>()defineEmits for type-safe events—defineEmits<{ (e: 'update', val: string): void }>()v-model is :modelValue + @update:modelValue—custom v-model with defineModel()default: () => ({})ref="name" + const name = ref(null)—names must match exactlyonMounted, not during setupref on component gives component instance—ref on element gives DOM elementv-for becomes array of refsonMounted for DOM access—component mounted to DOMonUnmounted for cleanup—subscriptions, timers, event listenersonBeforeMount runs before DOM insert—rarely needed but exists wrapperprovide('key', value) in parent—inject('key') in any descendantinject('key', defaultVal)—third param for factory functionuseRoute for current route—reactive, use in setupuseRouter for navigation—router.push('/path')beforeEach, beforeResolve, afterEach—return false to cancel with named views—multiple views per routev-if vs v-show—v-if removes from DOM, v-show toggles displayv-for required—v-for="item in items" :key="item.id".prevent.stop vs .stop.prevent renders outside component tree安装 Vue 后,可以对 AI 说这些话来触发它
Help me get started with Vue
Explains what Vue does, walks through the setup, and runs a quick demo based on your current project
Use Vue to avoid common Vue mistakes — reactivity traps, ref vs reactive, comp...
Invokes Vue with the right parameters and returns the result directly in the conversation
What can I do with Vue in my developer & devops workflow?
Lists the top use cases for Vue, with example commands for each scenario
将技能文件夹放到 ~/.claude/skills/vue/ 目录(个人级,所有项目可用),或 .claude/skills/vue/(项目级)。重启 AI 客户端后,用 /vue 主动调用,或让 AI 根据上下文自动发现并使用。
Vue 支持 Claude、Cursor、OpenClaw,可与这些 AI 平台无缝集成,扩展其能力。
Vue 可免费安装使用。请查阅仓库了解许可证信息。
Avoid common Vue mistakes — reactivity traps, ref vs reactive, computed timing, and Composition API pitfalls.
Vue 属于「Developer & DevOps」分类,该分类的技能帮助 AI 智能体在此领域执行专业任务。
Automate my developer & devops tasks using Vue
Identifies repetitive steps in your workflow and sets up Vue to handle them automatically