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

Add the using keyword per the "Explicit Resource Management" proposal #4135

Conversation

sufianrhazi
Copy link
Contributor

Changes

This ECMAScript proposal adds a new keyword (using). It's reached stage 3, which is "recommended for implementation":

The change itself is very small, I've just added the using keyword to the list of keywords in src/languages/lib/ecmascript.js. I've also updated an existing keyword test adding a case to ensure using is rendered as <span class="hljs-keyword">using</span> in a declaration.

I didn't update the CHANGES.md, since I'm not sure if I should cut a new version for this? But let me know what to do and I can do it.

Checklist

  • Added markup tests, or they don't apply here because...
  • Updated the changelog at CHANGES.md

Copy link
Member

@joshgoebel joshgoebel left a comment

Choose a reason for hiding this comment

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

Lets add the comment then this is good to merge!

@joshgoebel joshgoebel added the almost-there Getting close ot merging label Oct 20, 2024
@sufianrhazi
Copy link
Contributor Author

Thank you! Just added the suggested changes.

sufianrhazi and others added 2 commits October 24, 2024 17:46
This ECMAScript proposal adds a new keyword (`using`). It's reached
stage 3, which is "recommended for implementation"

Proposal: https://github.com/tc39/proposal-explicit-resource-management

ECMAScript proposal process: https://tc39.es/process-document/
Co-authored-by: Josh Goebel <me@joshgoebel.com>
@joshgoebel joshgoebel force-pushed the javascript-explicit-resource-management branch from 3adcade to f7e47ab Compare October 24, 2024 21:46
Copy link

Build Size Report

Changes to minified artifacts in /build, after gzip compression.

11 files changed

Total change +23 B

View Changes
file base pr diff
es/core.min.js 8.18 KB 8.18 KB +1 B
es/highlight.min.js 8.18 KB 8.18 KB +1 B
es/languages/coffeescript.min.js 1.45 KB 1.45 KB +3 B
es/languages/javascript.min.js 2.74 KB 2.74 KB +3 B
es/languages/livescript.min.js 1.6 KB 1.6 KB +2 B
es/languages/typescript.min.js 3.21 KB 3.21 KB +3 B
highlight.min.js 8.22 KB 8.22 KB +1 B
languages/coffeescript.min.js 1.46 KB 1.46 KB +3 B
languages/javascript.min.js 2.74 KB 2.75 KB +2 B
languages/livescript.min.js 1.61 KB 1.61 KB +2 B
languages/typescript.min.js 3.21 KB 3.22 KB +2 B

1 similar comment
Copy link

Build Size Report

Changes to minified artifacts in /build, after gzip compression.

11 files changed

Total change +23 B

View Changes
file base pr diff
es/core.min.js 8.18 KB 8.18 KB +1 B
es/highlight.min.js 8.18 KB 8.18 KB +1 B
es/languages/coffeescript.min.js 1.45 KB 1.45 KB +3 B
es/languages/javascript.min.js 2.74 KB 2.74 KB +3 B
es/languages/livescript.min.js 1.6 KB 1.6 KB +2 B
es/languages/typescript.min.js 3.21 KB 3.21 KB +3 B
highlight.min.js 8.22 KB 8.22 KB +1 B
languages/coffeescript.min.js 1.46 KB 1.46 KB +3 B
languages/javascript.min.js 2.74 KB 2.75 KB +2 B
languages/livescript.min.js 1.61 KB 1.61 KB +2 B
languages/typescript.min.js 3.21 KB 3.22 KB +2 B

@joshgoebel joshgoebel merged commit 2bd6ff6 into highlightjs:main Oct 24, 2024
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
almost-there Getting close ot merging
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants