-
Hello, everyone. I have a Sveltekit project with Svelte v5. It has Vitest, jsdom and @testing-library/svelte installed and working. I can use the However, the project I'm working on has a lifecycle that requires me to mount the component without the use of Well, my problem: |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
I've been facing the same problem and got this solution The key is adding I hope this helps. |
Beta Was this translation helpful? Give feedback.
-
Guys, apologies for the lack of response. @wobsoriano is correct. However, if you have my situation and using // vite.config.ts
import { svelteTesting } from '@testing-library/svelte/vite';
// And simply add it to the list of plug-ins.
...
plugins: [sveltekit(), svelteTesting()], |
Beta Was this translation helpful? Give feedback.
Guys, apologies for the lack of response. @wobsoriano is correct. However, if you have my situation and using
@testing-library/svelte
, then the way to go is use the plug-in provided by the library: