Skip to content

How to force webpack to use "node:" prefixes? #18265

Answered by alexander-akait
krutoo asked this question in Q&A
Discussion options

You must be logged in to vote

Got it, we need to implement nodePrefixForCoreModules here https://github.com/webpack/webpack/blob/main/lib/config/browserslistTargetHandler.js#L336, put version there, than implement supportsModePrefixForCoreModules() {} in RuntimeTemplate.js and use it everywhere we generate external exports for core modules, do you want to send a PR, if yes - feel free to do it, if no - feel free to open an issue, I will try to implement it tomorrow (easy task)

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@krutoo
Comment options

@alexander-akait
Comment options

Answer selected by krutoo
@alexander-akait
Comment options

@krutoo
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants