Index of every page on this site: llms.txt
All skills
onmax avatar

/vue

@b4e1a3f official
by Maxonmax/nuxt-skills729 stars
38
Run it yourself

Use when writing Vue 3 components and composables: `<script setup>` macros (defineProps, defineEmits, defineModel, defineSlots), refs, computed, watchers, lifecycle hooks, and Transition, Teleport, Suspense and KeepAlive.

Use this Skill: https://skilld.dev/gh/onmax/nuxt-skills/vue

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

SKILL.md

≈57 tokens for metadata: the name and description. ≈519 when used: this file. ≈4.4k more on demand in 3 files.

Description uses 2.8% of example budget

Before choosing a Skill, your Agent reads its name and description. All available Skills share that space.

  • A shorter description leaves more room for other Skills. This entry exceeds our 1% size suggestion.

In our Claude Code example, all Skill names and descriptions share 8,000 characters. This Skill uses ≈227 characters, or 2.8%.

The 1% threshold is a size suggestion. Longer descriptions can still fit.

Your model, settings, and other Skills decide how much text your Agent can read.

Example settings and source

The example uses a 200k-token context and default Claude Code settings. The count includes the name, description, separators, and when_to_use when present. Codex also counts local file paths.

Skit's source and limits: Codex 0.160.1, Claude Code 2.1.292.

Vue

Based on Vue 3.5, generated at 2026-09-25. Always use Composition API with <script setup lang="ts">.

Preferences

  • Prefer TypeScript over JavaScript
  • Prefer <script setup lang="ts"> over <script>
  • For performance, prefer shallowRef over ref if deep reactivity is not needed
  • Always use Composition API over Options API
  • Discourage using Reactive Props Destructure

Core

Topic Description Reference
Script Setup & Macros <script setup>, defineProps, defineEmits, defineModel, defineExpose, defineOptions, defineSlots, generics script-setup-macros
Reactivity & Lifecycle ref, shallowRef, computed, watch, watchEffect, effectScope, lifecycle hooks, composables core-new-apis

Features

Topic Description Reference
Built-in Components & Directives Transition, Teleport, Suspense, KeepAlive, v-memo, custom directives advanced-patterns

Quick Reference

Component Template

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

const props = defineProps<{
  title: string
  count?: number
}>()

const emit = defineEmits<{
  update: [value: string]
}>()

const model = defineModel<string>()

const doubled = computed(() => (props.count ?? 0) * 2)

watch(() => props.title, (newVal) => {
  console.log('Title changed:', newVal)
})

onMounted(() => {
  console.log('Component mounted')
})
</script>

<template>
  <div>{{ title }} - {{ doubled }}</div>
</template>

Key Imports

// Reactivity
import { ref, shallowRef, computed, reactive, readonly, toRef, toRefs, toValue } from 'vue'

// Watchers
import { watch, watchEffect, watchPostEffect, onWatcherCleanup } from 'vue'

// Lifecycle
import { onMounted, onUpdated, onUnmounted, onBeforeMount, onBeforeUpdate, onBeforeUnmount } from 'vue'

// Utilities
import { nextTick, defineComponent, defineAsyncComponent } from 'vue'

Source: SKILL.md on GitHub

No rule matched.

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No alertstoday5 checks · Risk SAFE
  • Gen Agent Trust Hubtoday

    This skill provides a comprehensive guide for writing Vue 3 components and composables using the Composition API and script setup syntax. It includes reference documentation for reactivity APIs, component macros, and built-in components like Transition and Teleport.

  • Socket4d

    No alerts

  • Snyktoday

    Risk: LOW · No issues

  • Runlayer8mo

    11 files scanned · No issues

  • ZeroLeaks7mo

    Score: 93/100 · 2 sections analyzed

Signed by skilld at b4e1a3f. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 14 hours ago.

Activeupdated 2 days ago
Other metadata
metadata
{
  "author": "Anthony Fu",
  "version": "2026.9.25",
  "source": "Generated from https://github.com/vuejs/docs, scripts at https://github.com/antfu/skills"
}

README badge

README badge for onmax/nuxt-skills/vue

Provides Composition API patterns, component architecture, testing practices, and TypeScript guidance for Vue 3 development. Covers .vue files, composables, reactivity, routing, and testing with Vitest and @vue/test-utils, organized as modular reference files loaded on-demand.

Generated from the current SKILL.md.

Does this skill cover Nuxt-specific patterns like server routes and file-based routing?
No. This skill focuses on Vue 3 components, composables, and client-side code. Load the separate `nuxt` skill for server routes, API endpoints, and file-based routing.
What testing framework does this skill assume?
Vitest with @vue/test-utils for component and composable testing, as documented in the testing reference.
Does this cover VueUse composables?
This skill references VueUse integration patterns in composables, but the dedicated `vueuse` skill is recommended for in-depth VueUse guidance.
Can I use this skill with Vue 2?
No. This skill targets Vue 3.5+ with Composition API patterns and modern reactivity features.
Should I load all the reference files at once?
No. Load only the reference files relevant to your current task to minimize context usage, such as references/components.md for .vue files or references/testing.md for test files.

Generated from the current SKILL.md. These answers refresh after source changes.