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

Missing well-known globals #3582

Merged
merged 2 commits into from
Dec 27, 2021
Merged

Missing well-known globals #3582

merged 2 commits into from
Dec 27, 2021

Conversation

acarstoiu
Copy link
Contributor

@acarstoiu acarstoiu commented Nov 14, 2021

Hello,

I have no idea why this hasn't been noticed before, but some well-known globals are missing from vars.js. Here's what I've added:

  • BigInt for ES 11
  • Intl for node
  • specify and it's counterpart xspecify for mocha
  • URLSearchParams for browser and node

This change is really easy to merge and I'm looking forward to seeing it in the next release.

BigInt for ES 11
Intl for node
specify, xspecify for mocha
URLSearchParams for browser and node
@coveralls
Copy link

coveralls commented Nov 14, 2021

Coverage Status

Coverage remained the same at 100.0% when pulling 15c66bb on acarstoiu:master into 057b1c6 on jshint:master.

@jugglinmike jugglinmike merged commit cc1adf6 into jshint:main Dec 27, 2021
@jugglinmike
Copy link
Member

Thanks!

setImmediate : true, // v0.9.1+
clearImmediate : true, // v0.9.1+
URL : true, // v6.13.0+
URLSearchParams: true // v6.13.0+
Copy link
Contributor

Choose a reason for hiding this comment

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

Not that it matters too much, but URLSearchParams was introduced in v10.0.0+

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Damn, I really checked the history section of URLSearchParams. I saw it was introduced in v6.13.0, but didn't notice that it became a global variable only in v10.0.0.

Copy link
Member

Choose a reason for hiding this comment

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

@coolaj86 Accurate documentation matters plenty! Thanks for checking our work :) Fixed via commit 06accfa

@acarstoiu
Copy link
Contributor Author

acarstoiu commented Dec 30, 2021

⚠️ There's a problem: I've just tested with the latest release 2.13.2 and in spite of these lines

  11: {
    BigInt             : false
  }

it does not work, BigInt is reported as "not defined" ❌

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.

None yet

4 participants