vue-pinia-best-practices 是做什麼的?
Pinia 儲存庫、狀態管理模式、儲存設定以及與儲存庫的反應性。
Pinia 儲存庫、狀態管理模式、儲存設定以及與儲存庫的反應性。
此技能專注於 Vue.js 生態系統中的 Pinia 狀態管理最佳實踐。它涵蓋了 Pinia 儲存庫的建立、設定和使用模式,包括如何有效地組織狀態、getter 和 actions。該技能解釋了選項式 (Options) 與組合式 (Setup) 儲存庫的差異,並指導開發者如何利用 Vue 的 Composition API(如 `ref()`, `reactive()`, `computed()`)來實現類型安全且具高度反應性的儲存庫結構。此外,它還探討了在元件中如何正確地與儲存庫互動,以確保狀態變更的可預測性與可維護性,是 Vue 3 開發者提升程式碼品質與團隊協作效率的實用參考。
npx skills add https://github.com/hyf0/vue-skills/tree/main/skills/vue-pinia-best-practicesInstalled? Explore more 程式設計與開發 skills: steipete/bluebubbles, steipete/eightctl, steipete/blucli · View all 6 →
Pinia 儲存庫、狀態管理模式、儲存設定以及與儲存庫的反應性。
This repo contains 7 individual skills — each has its own dedicated page.
Create a library-grade Vue composable that accepts maybe-reactive inputs (MaybeRef / MaybeRefOrGetter) so callers can pass a plain value, ref, or getter. Normalize inputs with toValue()/toRef() inside reactive effects (watch/watchEffect) to keep behavior predictable and reactive. Use this skill when user asks for creating adaptable or reusable composables.
MUST be used for Vue.js tasks. Strongly recommends Composition API with `<script setup>` and TypeScript as the standard approach. Covers Vue 3, SSR, Volar, vue-tsc. Load for any Vue, .vue files, Vue Router, Pinia, or Vite with Vue work. ALWAYS use Composition API unless the project explicitly requires Options API.
Vue 3 debugging and error handling for runtime errors, warnings, async failures, and SSR/hydration issues. Use when diagnosing or fixing Vue issues.
JSX syntax in Vue (e.g., class vs className, JSX plugin config).
Vue 3 Options API style (data(), methods, this context). Each reference shows Options API solution only.
Vue Router 4 patterns, navigation guards, route params, and route-component lifecycle interactions.
Use for Vue.js testing. Covers Vitest, Vue Test Utils, component testing, mocking, testing patterns, and Playwright for E2E testing.
Send and manage iMessages via BlueBubbles, including attachments, tapbacks, edits, replies, and groups.
Control Eight Sleep pods (status, temperature, alarms, schedules).
BluOS CLI (blu) for discovery, playback, grouping, and volume.
Create, search, and manage Bear notes via grizzly CLI.
Capture frames or clips from RTSP/ONVIF cameras.
Search GIF providers with CLI/TUI, download results, and extract stills/sheets.