·vitest

Vitest 測試框架模式,用於測試設置、異步測試、vi.* 模擬、快照和測試性能(以前稱為 test-vitest)。在編寫或調試 Vitest 測試時應該使用此技能。此技能不涵蓋 TDD 方法(使用 test-tdd 技能)、使用 MSW 進行 API 模擬(使用 test-msw 技能)或 Jest 特定的 API。

5安裝·0熱度·@thongdn-it

安裝

$npx skills add https://github.com/thongdn-it/react-agent-skills --skill vitest

SKILL.md

Comprehensive performance optimization and best practices guide for Vitest testing framework. Contains 44 rules across 8 categories, prioritized by impact to guide test writing, refactoring, and code review.

| 1 | Async Patterns | CRITICAL | async- | | 2 | Test Setup & Isolation | CRITICAL | setup- | | 3 | Mocking Patterns | HIGH | mock- | | 4 | Performance | HIGH | perf- | | 5 | Snapshot Testing | MEDIUM | snap- | | 6 | Environment | MEDIUM | env- | | 7 | Assertions | LOW-MEDIUM | assert- | | 8 | Test Organization | LOW | org- |

Read individual reference files for detailed explanations and code examples:

Vitest 測試框架模式,用於測試設置、異步測試、vi.* 模擬、快照和測試性能(以前稱為 test-vitest)。在編寫或調試 Vitest 測試時應該使用此技能。此技能不涵蓋 TDD 方法(使用 test-tdd 技能)、使用 MSW 進行 API 模擬(使用 test-msw 技能)或 Jest 特定的 API。 來源:thongdn-it/react-agent-skills。

查看原文

可引用資訊

為搜尋與 AI 引用準備的穩定欄位與指令。

安裝指令
npx skills add https://github.com/thongdn-it/react-agent-skills --skill vitest
分類
</>開發工具
認證
收錄時間
2026-02-01
更新時間
2026-02-18

快速解答

什麼是 vitest?

Vitest 測試框架模式,用於測試設置、異步測試、vi.* 模擬、快照和測試性能(以前稱為 test-vitest)。在編寫或調試 Vitest 測試時應該使用此技能。此技能不涵蓋 TDD 方法(使用 test-tdd 技能)、使用 MSW 進行 API 模擬(使用 test-msw 技能)或 Jest 特定的 API。 來源:thongdn-it/react-agent-skills。

如何安裝 vitest?

開啟你的終端機或命令列工具(如 Terminal、iTerm、Windows Terminal 等) 複製並執行以下指令:npx skills add https://github.com/thongdn-it/react-agent-skills --skill vitest 安裝完成後,技能將自動設定到你的 AI 程式設計環境中,可以在 Claude Code 或 Cursor 中使用

這個 Skill 的原始碼在哪?

https://github.com/thongdn-it/react-agent-skills