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

[mv3] Use globalThis instead of window #1130

Merged
merged 1 commit into from
Feb 7, 2024
Merged

Conversation

emaxx-google
Copy link
Collaborator

Switch a couple of places that use the "window" object to use "globalThis" instead. The latter is a better equivalent because it works in Manifest V3 Service Workers as well (in a Service Worker, "self" should be used instead of "window"; "globalThis" is an alias to either of those).

This contributes to the effort tracked by #1129.

Switch a couple of places that use the "window" object to use
"globalThis" instead. The latter is a better equivalent because
it works in Manifest V3 Service Workers as well (in a Service
Worker, "self" should be used instead of "window"; "globalThis" is
an alias to either of those).
Copy link

github-actions bot commented Feb 6, 2024

Continuous Integration: All tests passed.
C/C++ test coverage: 73.36% lines.

@emaxx-google emaxx-google merged commit 90d3245 into main Feb 7, 2024
13 checks passed
@emaxx-google emaxx-google deleted the mv3-global-this branch February 7, 2024 13:21
@emaxx-google
Copy link
Collaborator Author

Thanks for the reviews!

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

Successfully merging this pull request may close these issues.

2 participants