Skip to content
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

Window detection fails with jsdom #19

Closed
malcolmwhite opened this issue Jan 21, 2019 · 4 comments
Closed

Window detection fails with jsdom #19

malcolmwhite opened this issue Jan 21, 2019 · 4 comments

Comments

@malcolmwhite
Copy link

Thanks for making and maintaining this package -- it's a big help!

Using jsdom@11.5.1 and three-full@11.2.1, the cjs build fails to assign global to window. jsdom does provide a "global" object, but global instanceof Window returns false (here). The following check throws because GLOBAL is not defined.

Replacing this check with global.hasOwnProperty('window') fixes the issue for me.

@Itee
Copy link
Owner

Itee commented Mar 1, 2019

I extend the check about global window object in next release. Please feedback if this fix this issue.
Furthermore the debug warning is now display only for node.js setted with DEBUG env.

Thanks.

Itee added a commit that referenced this issue Mar 1, 2019
…g. And extend reliability on global window object. Fix #17, #19
@Itee
Copy link
Owner

Itee commented Apr 17, 2019

Could i close this issue or have you still trouble ?

@malcolmwhite
Copy link
Author

I moved from three-full to three + orbit-controls-ts, although I may be moving back soon. Feel free to close.

@malcolmwhite
Copy link
Author

This is now fixed for me, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants