Skip to content
Source
Sign inSign up
TanStack/query
Open History to see the last commit

vite.config.ts

31 lines694 Bytes

1import { defineConfig } from 'vitest/config'
2​
3import packageJson from './package.json'
4​
5export default defineConfig({
6 // fix from https://github.com/vitest-dev/vitest/issues/6992#issuecomment-2509408660
7 resolve: {
8 conditions: ['@tanstack/custom-condition'],
9 },
10 environments: {
11 ssr: {
12 resolve: {
13 conditions: ['@tanstack/custom-condition'],
14 },
15 },
16 },
17 test: {
18 name: packageJson.name,
19 dir: './src',
20 watch: false,
21 environment: 'jsdom',
22 coverage: {
23 enabled: true,
24 provider: 'istanbul',
25 include: ['src/**/*'],
26 exclude: ['src/__tests__/**'],
27 },
28 typecheck: { enabled: true },
29 restoreMocks: true,
30 },
31})