vue
하는 일
이 스킬은 최신 Composition API와 TypeScript로 Vue 3 사용자 인터페이스를 만드는 방법을 설명합니다. Vue로 웹 페이지와 앱을 만드는 개발자를 위한 것입니다.
사용하는 경우
- ✓Vue 단일 파일 컴포넌트를 작성하거나 편집할 때.
- ✓컴포넌트의 props, emits 또는 양방향 model을 정의해야 할 때.
- ✓Transition, Teleport 같은 내장 컴포넌트나 watcher를 사용하고 싶을 때.
스킬 링크
https://github.com/antfu/skills/blob/main/skills/vue/SKILL.md복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.
사용 방법
가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.
바로 붙여넣을 수 있는 메시지
Claude Code, Codex, Cursor용입니다. 프로젝트 폴더에서 실행하면 스킬이 설치됩니다.
SKILL.md를 다운로드해 에이전트의 스킬 폴더에 넣으세요.
AI에게 요청하는 예시
“입력한 텍스트를 내보내고 지우기 버튼을 보여 주는 검색창 Vue 컴포넌트를 만들어 주세요.”
매주 새 스킬 5개. 읽는 데 1분.
작동 방식
에이전트는 script setup과 TypeScript를 사용하는 Vue 3 Composition API 스타일을 따릅니다. 현재의 반응성 도구와 간단하고 효율적인 데이터 처리를 사용합니다.
기술 내용 (원본 SKILL.md)
작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.
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
shallowRefoverrefif 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'
자주 묻는 질문
Options API를 쓰나요?
아니요. Options API 대신 Composition API를 권장합니다.
어떤 스크립트 방식을 선호하나요?
lang ts를 붙인 script setup을 선호하며, 컴포넌트를 짧고 타입이 지정된 상태로 유지합니다.
내장 컴포넌트도 다루나요?
네. Transition, Teleport, Suspense, KeepAlive를 다룹니다.
상세 정보
작성자의 원본 설명
Vue 3 Composition API, script setup macros, reactivity system, and built-in components. Use when writing Vue SFCs, defineProps/defineEmits/defineModel, watchers, or using Transition/Teleport/Suspense/KeepAlive.
repo: antfu/skills
인기도
- GitHub 스타
- 6.0k
- 순위
- #14448
- 라이선스
- MIT
- 업데이트
- 2026. 10. 30.
댓글
- …
이 저장소의 다른 스킬
antfu-create-pr
6.0k에이전트가 내 브랜치에서 GitHub 풀 리퀘스트를 열도록 돕고, 무엇이 왜 바뀌었는지 쉽게 설명한 요약을 함께 씁니다.
antfu-issue-triage
6.0k에이전트가 열린 GitHub 이슈와 풀 리퀘스트를 살펴 중복과 이미 해결된 항목을 찾고, 실행 전에 사용자에게 먼저 묻도록 돕습니다.
antfu-query
6.0k에이전트가 계획을 한 번에 한 단계씩 질문해, 함께 명확하고 검증된 이해에 이르도록 돕습니다.
antfu-simplify
6.0k에이전트가 코드 변경을 필요 없는 부분을 빼고 가장 작고 올바른 형태로 줄이도록 돕습니다.
비슷한 스킬
angular-developer
280k에이전트가 Angular 코드를 만들고 프로젝트 구조를 조언하도록 돕습니다. 새 프로젝트 시작, 코드 부분 생성, 성능과 접근성 개선에 유용합니다.
frontend-a11y
280k모든 사람이 웹 인터페이스를 쓸 수 있도록 에이전트를 돕습니다. 웹사이트와 앱이 화면 읽기 프로그램과 키보드 탐색에서 잘 작동하도록 합니다.
frontend-patterns
280k프론트엔드 개발의 현대적인 패턴을 적용하도록 에이전트를 돕습니다. React와 Next.js에서 성능을 최적화하고, 상태를 관리하며, 모범 사례를 따릅니다.