Blob is not instance of Blob
See original GitHub issueIt appears that Blob
is not an instance of Blob
. Here’s a minimal repro on StackBlitz using Vitest:
https://stackblitz.com/edit/happy-dom-bug-blob-prototype?file=README.md
This caused the following error when using the @web-std/file
package after upgrading from vitest@0.11.0
to vitest@0.12.0
TypeError: Class extends value does not have valid prototype property undefined Object.<anonymous> node_modules/@web-std/file/dist/src/file.cjs:59:15 Object.<anonymous> node_modules/@web-std/file/dist/src/lib.node.cjs:6:12
I’m not sure if there’s also a bug in Vitest or not, but the fact that Blob.prototype
is undefined
appears to be the root cause. The error only occurs when using the happy-dom
environment, so I believe this is the appropriate place to open an issue.
Issue Analytics
- State:
- Created a year ago
- Comments:6 (3 by maintainers)
Top GitHub Comments
I am continuing the work in #520 right now where we will replace the Happy DOM URL with Nodes version of it. Hopefully that will solve this issue then.
@nakleiderer this should be solved in the latest version of Vitest 🙂