We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e8f7b08 commit 7dac059Copy full SHA for 7dac059
docs/config/index.md
@@ -68,6 +68,21 @@ export default mergeConfig(viteConfig, defineConfig({
68
`mergeConfig` helper is availabe in Vitest since v0.30.0. You can import it from `vite` directly, if you use lower version.
69
:::
70
71
+If your vite config is defined as a function, you can define the config like this:
72
+```ts
73
+import { defineConfig, mergeConfig } from 'vitest/config'
74
+import viteConfig from './vite.config'
75
+
76
+export default defineConfig(configEnv => mergeConfig(
77
+ viteConfig(configEnv),
78
+ defineConfig({
79
+ test: {
80
+ exclude: ['packages/template/*'],
81
+ },
82
+ })
83
+))
84
+```
85
86
## Options
87
88
:::tip
0 commit comments