This message was deleted.
# ask-questions
w
This message was deleted.
f
@happy-autumn-40938?
a
My worker index.ts has only these imports:
Copy code
import { GrowthBook } from "@growthbook/growthbook";
import { getPayloadFromKV } from "@growthbook/edge-cloudflare";
f
@kind-autumn-215
h
I don't have an answer on how to make CJS play nicely with vitest in this scenario, but I can look into it. Possibly dual export to ESM + CJS. I have had some success in the past via forcing modules / renaming test runners to
.mjs
😿 1
b
Could you perhaps recommend a test suite which would not have such issues with growthbook?
@happy-autumn-40938 in case this got burried
h
You could perhaps try jest, although I don't particularly love recommending that. I'll be working on a new Edge SDK build over the next couple of weeks and will do some testing in vitest at that time. This may mean that the SDK will be dual-packaged for CJS and ESM.
🙌 1
121 Views