Open ipeychev opened 6 years ago
Hi @ipeychev!
If I remember correctly, in the commit you linked, we removed the usage of document
globally, so it wouldn’t fail when simply imported.
We did this under the assumption that if you used this API checkAnimatinoEventName
you were making it safely from a browser
environment, and the calling code would be wrapping it in an isServerSide
if clause.
Based on the stacktrace, though, it looks like this is being called from events
inside metal-dom
, so we will take a look.
As I mentioned, the usage of this can be found in events.js
and is:
if (!isServerSide()) {
registerEvents();
}
Seeing this error, this might be related to Consider removing NODE_ENV
check from isServerSide
mismatching the environment.
This commit uses
document
, but in Node there is no such thing. This breaks most of the tests of Marble components.