Unable to run any vitest tests on initial launch

I created a new solid start project via bun create and added the default vitest setup. I was trying to just see if any test would run, and I'm getting this error. Anyone know how to solve this? I haven't touched any defaults yet.
No description
6 Replies
Erik Demaine
Erik Demaine2w ago
It looks like cssstyle uses CommonJS but css-color supports only ESM?
crutchcorn
crutchcorn2w ago
I'm working on a PR upstream that will fix this problem. I ran into it as well
crutchcorn
crutchcorn2w ago
To temporarily fix it, pin cssstyle to 4.1.0 using your package.json's override functionality, since 4.2.0 is where things broke: https://github.com/jsdom/cssstyle/commits/main/
GitHub
Commits · jsdom/cssstyle
A Node.js implementation of the CSS Object Model CSSStyleDeclaration interface - Commits · jsdom/cssstyle
crutchcorn
crutchcorn2w ago
I'll follow up on this issue with a list of GH issues and PR in a moment
crutchcorn
crutchcorn2w ago
GitHub
ESM errors due to require of sub-package · Issue #182 · jsdom/css...
When running a new project with JSDom via Vitest, I get the following error: Error: require() of ES Module C:\Users\crutchcorn\git\TanStack\form\nodemodules.pnpm@[email protected]\node...
quinnvaughn
quinnvaughnOP2w ago
Awesome thanks!

Did you find this page helpful?