Open morsh opened 5 months ago
+1 for this. I was just about to raise this issue but saw this.
I'm using an Angular project with a Jest test around it. I'll spend some time looking for a workaround and report back if I find one
I'm getting the same error but with @fluentui/react-components. I suspect the issue is within a dependency, since reverting the version of react-components did not fix the issue for me
Library
Web Components (@fluentui/web-components)
System Info
Are you reporting Accessibility issue?
no
Reproduction
https://codesandbox.io/p/github/morsh/svelte-typescript-jest/main?import=true
Bug Description
Actual Behavior
In test setup:
when running
pnpm test
:SyntaxError: Unexpected token 'export'
Expected Behavior
Should run and pass tests.
Usually, with jest, you can set
moduleNameMapper
for a cjs module, but web-components don't supply one.Logs
Requested priority
Blocking
Products/sites affected
No response
Are you willing to submit a PR to fix?
yes
Validations