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
createComment is not a function error - lit and lit-html 2.3.0 #3216
Comments
Thank you for the report and repro! I get an error in the console We did recently make a change that could be related to this issue: #3156 |
I think the issue here is that There appears to be an option to potentially override that here https://vitest.dev/config/#transformmode-web I tried just grabbing all .js files and forcing the transform by inlining all the dependencies in your stackblitz repro and the test command does seem to work. |
@augustjk yes thanks indeed it works, is this a work around? or do you think lit team has permanent fix? im not sure also if this is lit or vitest/vite issue. |
@aomarks if you think this not lit issue we can close this |
While it's work-aroundable, perhaps we can also add some check here to use an existing lit/packages/lit-html/src/lit-html.ts Lines 347 to 353 in ecdb3bc
|
Which package(s) are affected?
Lit Core (lit / lit-html / lit-element / reactive-element)
Description
using vite and vitest error with latest version of lit
Reproduction
Please check stackblitz URL
https://stackblitz.com/edit/vitejs-vite-omm8ny
Workaround
downgrade to
lit@2.2.8
andlit-html@2.2.7
versionIs this a regression?
Yes. This used to work, but now it doesn't.
Affected versions
2.3.0
Browser/OS/Node environment
Chrome 103
MacOSX
Node 16
The text was updated successfully, but these errors were encountered: