ClaudeCodeMod

All shelves / Skills

vitest

antfu/skills · 49.2k installs · 6K stars

Skill Vitest is a next-generation testing framework powered by Vite. It provides a Jest-compatible API with native ESM, TypeScript, and JSX support out of the box. Vitest shares the same config, transformers, resolvers, and plugins with your Vite app.

Marked Remote Code Execution · Data Exfiltration · Indirect Prompt Injection

Listed in: Best skills for testing

Install

The repo has no one-line install. Follow its README.

Open the repo

Files

SKILL.md

Vitest is a next-generation testing framework powered by Vite. It provides a Jest-compatible API with native ESM, TypeScript, and JSX support out of the box. Vitest shares the same config, transformers, resolvers, and plugins with your Vite app.

Key Features:

  • Vite-native: Uses Vite's transformation pipeline for fast HMR-like test updates
  • Jest-compatible: Drop-in replacement for most Jest test suites
  • Smart watch mode: Only reruns affected tests based on module graph
  • Native ESM, TypeScript, JSX support without configuration
  • Multi-threaded workers for parallel test execution
  • Built-in coverage via V8 or Istanbul
  • Snapshot testing, mocking, and spy utilities

The skill is based on Vitest 5.1.0-beta.1, generated at 2026-10-23.

Core

Topic Description Reference
Configuration Vitest and Vite config integration, defineConfig usage core-config
CLI Command line interface, commands and options core-cli
Test API test/it function, modifiers like skip, only, concurrent core-test-api
Describe API describe/suite for grouping tests and nested suites core-describe
Expect API Assertions with toBe, toEqual, matchers and asymmetric matchers core-expect
Hooks beforeEach, afterEach, beforeAll, afterAll, aroundEach core-hooks

Features

Topic Description Reference
Mocking Mock functions, modules, timers, dates with vi utilities features-mocking
Snapshots Snapshot testing with toMatchSnapshot and inline snapshots features-snapshots
Coverage Code coverage with V8 or Istanbul providers features-coverage
Test Context Test fixtures, context.expect, test.extend for custom fixtures features-context
Concurrency Concurrent tests, parallel execution, sharding features-concurrency
Filtering Filter tests by name, file patterns, tags features-filtering
Test Tags Label tests with tags to filter runs and apply shared options features-test-tags
Reporters Built-in reporters, default selection, CI/output config features-reporters
Benchmarking Write benchmarks with the bench fixture (Tinybench) features-benchmarking

Advanced

Topic Description Reference
Vi Utilities vi helper: mock, spyOn, fake timers, hoisted, waitFor advanced-vi
Environments Test environments: node, jsdom, happy-dom, custom advanced-environments
Type Testing Type-level testing with expectTypeOf and assertType advanced-type-testing
Projects Multi-project workspaces, different configs per project advanced-projects

Facts

Kind
Skill
Repo
antfu/skills
Group
Uncategorized
Installs
49.2k
Stars
6K

Same name on this shelf 10

  1. 3661vitestpproenca/dot-skills8k
  2. 5311vitestsentimony/skills4.8k
  3. 7145vitestonmax/nuxt-skills3.3k
  4. 8074vitestsupabase/supabase2.8k
  5. 10629vitestjezweb/claude-skills1.8k
  6. 13328vitestbobmatnyc/claude-mpm-skills828

Search the shelf for “vitest”

From the same repo

  1. 963viteantfu/skills42.7k
  2. 1071vueantfu/skills37.1k
  3. 1500nuxtantfu/skills25k

Also in Best skills for testing

  1. 12tddmattpocock/skillsTest-driven development. Use when the user wants to build features or fix bugs test-first, mentions "red-green-refactor", or wants integration tests.1.3M
  2. 292test-driven-developmentobra/superpowersUse when implementing any feature or bugfix, before writing implementation code289.3k
  3. 324playwright-climicrosoft/playwright-cli224.6k