-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docs: Need clearer description about triple slash command
#1019
Comments
I couldn't get this to work following the instructions as documented. The thing that was missing from my understanding was that 'vitest' needed to be imported for the reference to work. Could we add that into the docs as well? ie:
|
@meshantz I had the exact same issue. I don't know what the problem was exactly, but I nuked my lock file and reinstalled and that did the trick. rm yarn.lock
yarn install Note: you can either 1) use the triple reference in your {
"compilerOptions": {
"types": ["vitest/globals"]
}
} It might have been because I had multiple versions of vite installed unintentionally (try running |
Clear and concise description of the problem
In the vitest documentation, i think we should clearer description about
triple slash command
,👇 This is the description of aaa in the documentation
To configure vitest itself, add test property in your Vite config. You'll also need to add a reference to Vitest types using a triple slash command at the top of your config file, if you are importing defineConfig from vite itself.
Suggested solution
should we update the doc to this ? 👇
To configure vitest itself, add test property in your Vite config. You'll also need to add a reference to Vitest types using a triple slash command at the top of your config file, if you are importing defineConfig from vite itself.
using defineConfig from
vite
you should follow this:using
defineConfig
fromvitest/config
you should follow this:Alternative
No response
Additional context
No response
Validations
The text was updated successfully, but these errors were encountered: