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

Should use globalThis instead of global #1762

Closed
davbrito opened this issue Apr 24, 2022 · 4 comments
Closed

Should use globalThis instead of global #1762

davbrito opened this issue Apr 24, 2022 · 4 comments
Assignees
Labels
bug filed A bug has been filed upstream for this issue

Comments

@davbrito
Copy link

davbrito commented Apr 24, 2022

The global object is available on node but not in browser environments. so you should use the globalThis object instead, which is the standard way to reference the global object on every environment.

const toplevel = global.window || global;

@davbrito davbrito changed the title Shold use globalThis instead of global Should use globalThis instead of global Apr 24, 2022
@makarandp0 makarandp0 self-assigned this Apr 25, 2022
@makarandp0 makarandp0 added the bug filed A bug has been filed upstream for this issue label Apr 25, 2022
@makarandp0
Copy link
Contributor

Thank you for the tip @davbrito. I have filed a task for this, and we will take it up soon. (VIDEO-9592)

@davbrito
Copy link
Author

I think this is solved by #1752 . Am I right?

@makarandp0
Copy link
Contributor

Yep. Should be released soon

@makarandp0
Copy link
Contributor

Hello @davbrito - This is released as part of 2.21.2, Thanks again for the tip!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug filed A bug has been filed upstream for this issue
Projects
None yet
Development

No branches or pull requests

2 participants