Vue Options API Best Practices

Skill

For Vue 3 projects on the Options API (data(), methods, this): how to get TypeScript inference with defineComponent and type props, event handlers and computed values, plus gotchas like avoiding arrow functions in methods and lifecycle hooks and not sharing debounced state across instances.

vuejs-ai/skills · skills/vue-options-api-best-practices2.9k
GitHub에서 보기
README
name: vue-options-api-best-practices
description: "Vue 3 Options API style (data(), methods, this context). Each reference shows Options API solution only."
version: 2.0.0
license: MIT
author: github.com/vuejs-ai

Vue.js Options API best practices, TypeScript integration, and common gotchas.

TypeScript

Methods & Lifecycle