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

fix: support node[[X].Y] as a target (fixes #1247) #1248

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

iamstarkov
Copy link

No description provided.

@iamstarkov iamstarkov changed the title node target fixes #1247 support node[[X].Y] as target (fixes #1247) Feb 11, 2025
@iamstarkov
Copy link
Author

iamstarkov commented Feb 12, 2025

Note that webpack runtime code is not the same as the user code you write, you should transpile those code with transpilers like Babel if you want to target specific environments, e.g, you have arrow functions in source code and want to run the bundled code in ES5 environments. Webpack won’t transpile them automatically with a targetconfigured.
https://webpack.js.org/configuration/target/#target

maybe this the reason why why nodeX.Y isnt doing transpiling

update: I realized #1247 issue is two fold: supporting node as a target and then figure out why Set polyfills are not injected when compiling node22 code to node20. and I decided to address it one by one.

@iamstarkov iamstarkov changed the title support node[[X].Y] as target (fixes #1247) fix: support node[[X].Y] as a target (fixes #1247) Feb 16, 2025
@iamstarkov iamstarkov marked this pull request as ready for review February 16, 2025 13:45
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.

1 participant