vue

Apply Vue 3 Composition API and script setup macros to build single-file components.

Updated Aug 23, 2026
One-click install
npx skills add https://github.com/BINGWU2003/student-side-job-platform --skill vue-bingwu2003
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: vue
Source: https://github.com/BINGWU2003/student-side-job-platform/tree/main/.agents/skills/vue
Command: npx skills add https://github.com/BINGWU2003/student-side-job-platform --skill vue-bingwu2003

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Vue 3 developers often struggle to scaffold and consistently apply the Composition API, script setup macros, and robust reactivity patterns across SFCs. This skill streamlines understanding and applying Vue's core features to build scalable components.

Core Features & Use Cases

  • Understand and apply the Vue 3 Composition API, <script setup>, defineProps/defineEmits/defineModel, and practical reactivity patterns (ref, reactive, computed, watch).
  • Use built-in components and directives (Transition, Teleport, Suspense, KeepAlive) to craft polished UI without boilerplate.
  • Real-world use: build a reusable, typed SFC library for a frontend app, including prop definitions, event contracts, and lifecycle handling.

Quick Start

Create a Vue 3 single-file component using script setup lang="ts" and defineProps/defineEmits to implement a small interactive widget.

Frequently Asked Questions about vue

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I use Vue 3 Composition API with script setup to build a single-file component?

To use Vue 3 Composition API with script setup, add the setup attribute to your script tag in a single-file component. This enables compiler macros like defineProps and defineEmits to directly structure interactive widgets without boilerplate.

What is the best way to define props and emits in Vue 3 SFCs?

The best way to define props and emits in Vue 3 SFCs is using the defineProps and defineEmits compiler macros. These macros provide typed contracts and event definitions directly within the script setup block for maintainable UI code.

How does Vue 3 reactivity work with ref, reactive, and computed?

Vue 3 reactivity works by using ref and reactive primitives to track state changes, and computed properties to derive reactive values. Watchers then observe these reactive updates to execute side effects seamlessly within single-file components.

Can I use built-in components like Transition, Teleport, and Suspense in Vue 3?

Yes, you can use built-in components like Transition, Teleport, and Suspense in Vue 3. These components help craft polished UIs by handling animations, portal rendering, and asynchronous component loading without requiring external boilerplate.

When do I need defineModel for two-way binding in Vue 3?

You need defineModel in Vue 3 when creating reusable SFC libraries that require two-way binding between parent and child components. It simplifies defining model contracts alongside defineProps and defineEmits for robust component communication.

Does Vue 3 script setup support TypeScript for typed components?

Yes, Vue 3 script setup supports TypeScript by setting lang="ts" on the script tag. This allows you to implement strongly typed interactive widgets and apply practical reactivity patterns across your scalable single-file components.