Skip to content

Conversation

@OlduwanSteve
Copy link
Contributor

@OlduwanSteve OlduwanSteve commented May 27, 2017

Add hard coded integer constants for *_SAFE_INTEGER which are not available on IE

Fixes #4294

var dataMin = Number.MAX_SAFE_INTEGER;
var dataMax = Number.MIN_SAFE_INTEGER;
// Integer constants are from the ES6 spec.
var dataMin = Number.MAX_SAFE_INTEGER || 9007199254740991;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there any advantage to keep the constants here compared to simply hard code these values?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only that it seems more future proof. It looks like Edge supports these, so in 'the future' the constants should be used everywhere and the hard coded values will never come into play. I've no strong opinion on this so let me know if you'd like it changed.

Copy link
Member

@simonbrunel simonbrunel May 27, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense, thanks!

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants