Closed
Description
When scaffolding a new app with TypeScript and Vitest using npm init vue@latest
, there's a TypeScript error in vitest.config.ts related with the usage of mergeConfig.
Argument of type 'UserConfigExport' is not assignable to parameter of type 'UserConfig | Promise'.
Type 'UserConfigFn' is not assignable to type 'UserConfig | Promise'.ts(2345)
It seems the actual types in use for the "mergeConfig" arguments are UserConfigExport, but "mergeConfig" is expecting them to be of type UserConfig.
Here are the prompt selections:
After installing dependencies, the following error shows up in vitest.config.ts: