vue-best-practices.mdc 510 B

1234567891011
  1. ---
  2. description: Best practices for Vue 3 applications
  3. globs: *.vue
  4. alwaysApply: false
  5. ---
  6. - Use Vue3 Composition API for better code organization and reusability
  7. - Components should be automatically split into multiple small components that are easy to maintain
  8. - Implement proper reactivity with `ref` and `reactive`
  9. - Use `<script setup>` for concise component logic
  10. - Leverage Vue's built-in directives like `v-model` for form handling
  11. - Implement proper error handling with `try/catch` in component setup