-
Notifications
You must be signed in to change notification settings - Fork 12.6k
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
URL is missing from Window interface #3753
Comments
@zhengbli can you take a look |
I'm trying to help but that's the only thing I can do. The Window Interface is in the dom.generated.d.ts source file: https://github.com/Microsoft/TypeScript/blob/master/src/lib/dom.generated.d.ts#L11848. I can't find the way to create the URL object. |
According to https://developer.mozilla.org/en-US/docs/Web/API/Window/URL:
we should add a constructor for interface interface URL {
createObjectURL(object: any, options?: ObjectURLOptions): string;
revokeObjectURL(url: string): void;
}
declare var URL: {
prototype: URL;
new(): URL;
} Then for interface window ... {
...
URL: URL
...
} |
The URL interface is already created: https://github.com/Microsoft/TypeScript/blob/master/src/lib/dom.generated.d.ts#L10773-L10776 but it isn't instantiated. |
Actually after trying out on various browsers, we found that the constructor of interface |
From PR #3741
The text was updated successfully, but these errors were encountered: