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

Remove DOM type references. #1327

Merged
merged 1 commit into from
Jan 11, 2022
Merged

Remove DOM type references. #1327

merged 1 commit into from
Jan 11, 2022

Conversation

dcr-stripe
Copy link
Contributor

r? @richardm-stripe

Summary

Removes the references to DOM types, specifically the fetch function (and its return/stream types) as well as the SubtleCrypto interface.

Unfortunately this reference pollutes the global namespace for Node packages, which don't include these DOM APIs.

We lose some type-safety here by switching to any but the alternative would be copying in the types from the DOM typescript definitions. These are quite substantial (eg. the fetch input arguments require many types) and would require keeping these types in sync with moving web standards.

Motivation

#1326

@dcr-stripe dcr-stripe merged commit f7fe155 into master Jan 11, 2022
@dcr-stripe dcr-stripe deleted the dcr-loosen-dom-types branch January 11, 2022 22:57
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

Successfully merging this pull request may close these issues.

2 participants