Skip to content
This repository was archived by the owner on Jan 13, 2024. It is now read-only.

Add classPrivateMethods plugin to babel parser - #1249

Closed
hcldan wants to merge 2 commits into
vercel:mainfrom
hcldan:patch-1
Closed

hcldan wants to merge 2 commits into
vercel:mainfrom
hcldan:patch-1

Conversation

@hcldan

@hcldan hcldan commented Jul 7, 2021

Copy link
Copy Markdown

Fixes #1248

I'd like to be able to pass in my own version of babel parser, configured with my own set of plugins.

Fixes vercel#1248 

I'd like to be able to pass in my own version of babel parser, configured with my own set of plugins.
@github-actions

github-actions Bot commented Oct 6, 2021

Copy link
Copy Markdown

This pull-request is stale because it has been open 90 days with no activity. Remove the stale label or comment or this will be closed in 5 days. To ignore this pull-request entirely you can add the no-stale label

@github-actions github-actions Bot added the Stale label Oct 6, 2021
@github-actions

Copy link
Copy Markdown

This pull-request is now closed due to inactivity, you can of course reopen or reference this pull-request if you see fit.

@github-actions github-actions Bot closed this Oct 11, 2021
@hcldan

hcldan commented Apr 27, 2022

Copy link
Copy Markdown
Author

@leerob what's the story here for people wanting to pitch in? I never got any comments from a maintainer.

@robertsLando

Copy link
Copy Markdown
Contributor

@hcldan Sorry I may have missed this one

@robertsLando robertsLando reopened this Apr 27, 2022
@robertsLando
robertsLando requested a review from jesec April 27, 2022 16:08

@robertsLando robertsLando left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@hcldan

hcldan commented Apr 27, 2022

Copy link
Copy Markdown
Author

Thank you!

@jesec

jesec commented Apr 27, 2022

Copy link
Copy Markdown
Contributor

I would recommend users to transform/transpile their projects first, if novel syntaxes or new JS features are used.

pkg supports older Node.js runtime so the built-in parser configuration is rather conservative. This makes sure that you would get an error if you attempt to use features that are only available in newer Node.js runtimes. Note that pkg only uses Babel to walk dependencies. It does not touch your source code.

classPrivateMethods is only available on Node 12+. I can merge this after we dropped support for Node 8 and 10. Alternatively, we can have different parser configurations based on the Node target.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Error! This experimental syntax requires enabling the parser plugin: 'classPrivateMethods' (406:2)

3 participants