Replies: 5 comments
-
The |
Beta Was this translation helpful? Give feedback.
-
I have a browser-application, and I have unit tests for it. The tests include things like "document.createElement", and other browser-env related stuff, so I need to use "jsdom" environment on the "jest" side. Are you saying that Skia Canvas is only supposed to work in the "node" environment? |
Beta Was this translation helpful? Give feedback.
-
Right, Skia Canvas is an emulation/extension of the canvas API for Node (which doesn't have a built-in canvas the way the browser environment does). In the browser you can just use the |
Beta Was this translation helpful? Give feedback.
-
How is one supposed to write unit tests for their frontend applications that includes canvas functionalities, then? 😭 |
Beta Was this translation helpful? Give feedback.
-
I don't want to "ruin anyone's business", but I stumbled upon Thank you anyway |
Beta Was this translation helpful? Give feedback.
-
I'm trying to use skia-canvas to have proper unit-tests for some of our canvas-2d related features with jest. Unfortunately, when I import it, this is what I get:
Test suite failed to run
What am I missing?
Beta Was this translation helpful? Give feedback.
All reactions