Open History to see the last commit
1import { defineConfig, mergeConfig } from 'vitest/config'
2import { tanstackViteConfig } from '@tanstack/config/vite'
3import react from '@vitejs/plugin-react'
4import packageJson from './package.json'
5import type { UserConfig } from 'vitest/config'
6β
7const config = defineConfig({
8 plugins: [react()] as UserConfig['plugins'],
9 test: {
10 name: packageJson.name,
11 dir: './tests',
12 watch: false,
13 environment: 'jsdom',
14 typecheck: { enabled: true },
15 },
16})
17β
18export default mergeConfig(
19 config,
20 tanstackViteConfig({
21 entry: './src/index.ts',
22 srcDir: './src',
23 }),
24)