-
Notifications
You must be signed in to change notification settings - Fork 63
Closed
Labels
good first issueGood for newcomersGood for newcomershelp wantedExtra attention is neededExtra attention is needed
Description
Hey, thanks for creating this awesome package!
I've found that the viteConfig prop as part of defineConfig doesn't reflect the actual configuration accepted. In fact, the only property that it expects is test. However, it works anyway 👍. So I'm assuming it's a type issue.
This is the config I used. Had to add a plugin for path aliases.
import tsconfigPaths from 'vite-tsconfig-paths'
export default defineConfig({
viteConfig: {
// @ts-expect-error this is actually the correct way to pass vitest config
plugins: [tsconfigPaths()],
},
});
Here's the TS error
Object literal may only specify known properties, and 'plugins' does not exist in type '{ test?: StrictOmit<UserConfig, "mode" | "include" | "setupFiles" | "testTimeout" | "maxConcurrency" | "browser" | "config" | "watch" | "reporters" | "testNamePattern"> | undefined; }'.ts(2353)
types.d.ts(125, 9): The expected type comes from property 'viteConfig' which is declared here on type 'Config'
Version: "1.0.0-beta.8"
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
good first issueGood for newcomersGood for newcomershelp wantedExtra attention is neededExtra attention is needed