-
Notifications
You must be signed in to change notification settings - Fork 12.5k
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
lib.es5.d.ts: Date#toGMTString declaration is missing #13622
Comments
Why not use the non-deprecated method instead? |
I use. But, anyway I think, that this method should be declared, because it's available from JavaScript. |
You can manually do: interface Date {
toGMTString(): string;
} |
@saschanaz Issue about missing declaration in |
The method is intentionally redacted from the declaration file as it has since been removed from the standard. The lib files are commutative, i.e. From a correctness point of view, the API should be included, but marked as deprecated. We can revisit this after #390 is supported. |
Declining due to lack of other feedback |
TypeScript Version: 2.2.0-dev.20170117
Code
Expected behavior:
No errors.
Actual behavior:
Error:
Property 'toGMTString' does not exist on type 'Date'.
MDN link https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toGMTString
This method is deprecated, but still available in browsers and Node.js.
The text was updated successfully, but these errors were encountered: