Skip to content

Add Math property to Window #125

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

Closed
wants to merge 1 commit into from

Conversation

zuzusik
Copy link
Contributor

@zuzusik zuzusik commented Jun 23, 2016

@msftclas
Copy link

Hi @zuzusik, I'm your friendly neighborhood Microsoft Pull Request Bot (You can call me MSBOT). Thanks for your contribution!
You've already signed the contribution license agreement. Thanks!

The agreement was validated by Microsoft and real humans are currently evaluating your PR.

TTYL, MSBOT;

@mhegazy
Copy link
Contributor

mhegazy commented Jun 23, 2016

As noted in microsoft/TypeScript#9325 (comment), i do not see why we need to define this but not other ones, e.g. NaN, Array, Date, Number, String, HTMLElement, etc..

@saschanaz
Copy link
Contributor

From microsoft/TypeScript#9325 (comment):

The standard library does not support using Window as the global polluter. i.e. adding members on Window are not reflected on the global and adding members on the global are not reflected on Window.

Not sure what this means, can you elaborate more? I thought JSON, Math, RegExp, etc are all accessible via window and delete window.RegExp makes the global member inaccessible.

@zuzusik
Copy link
Contributor Author

zuzusik commented Jun 29, 2016

@mhegazy then I suppose you should also delete Blob and URL from window?

In general this sounds strange to me. If these props exist on window, why shouldn't it be described in TypeScript definitions?

@saschanaz
Copy link
Contributor

saschanaz commented Jun 29, 2016

@zuzusik Web specifications explicitly say Exposed=Window in their WebIDL but JS standard libraries do not. However, not really understand TypeScript policy yet...

@mhegazy
Copy link
Contributor

mhegazy commented Jul 11, 2016

This file is autogrenerated mostly, so we shown ones marked as such. i am fine adding more to window but do not see why add Math, but nothing else.

@mhegazy
Copy link
Contributor

mhegazy commented Aug 15, 2017

As i have noted earlier, do not see why Math is any different from other declarations. either we do them all or nothing.

@mhegazy mhegazy closed this Aug 15, 2017
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.

4 participants