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

feat: reinstate ESM transpilation for NFT #790

Merged
merged 10 commits into from Nov 4, 2021
Merged

Conversation

eduardoboucas
Copy link
Member

- Summary

Reinstates ESM transpilation when using NFT, which was temporarily disabled in #786. It's sitting behind a nftTranspile feature flag.

Unlike the initial implementation introduced by #759, this PR only transpiles a file to ESM (and patches any corresponding package.json) if all its parents are ESM files themselves, also candidates for transpilation.

- Test plan

Existing tests adjusted accordingly.

- A picture of a cute animal (not mandatory but encouraged)

gettyimages-144862048

@eduardoboucas eduardoboucas added the type: feature code contributing to the implementation of a feature and/or user facing functionality label Nov 4, 2021
src/runtimes/node/bundlers/nft/es_modules.ts Outdated Show resolved Hide resolved
tests/main.js Outdated Show resolved Hide resolved
src/runtimes/node/bundlers/nft/es_modules.ts Outdated Show resolved Hide resolved
eduardoboucas and others added 3 commits November 4, 2021 13:25
Co-authored-by: Netlify Team Account 1 <90322326+netlify-team-account-1@users.noreply.github.com>
Co-authored-by: Netlify Team Account 1 <90322326+netlify-team-account-1@users.noreply.github.com>
eduardoboucas and others added 2 commits November 4, 2021 13:56
Co-authored-by: Netlify Team Account 1 <90322326+netlify-team-account-1@users.noreply.github.com>
@eduardoboucas eduardoboucas merged commit 6a9a9f8 into main Nov 4, 2021
@eduardoboucas eduardoboucas deleted the feat/nft-esm-transpile branch November 4, 2021 14:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: feature code contributing to the implementation of a feature and/or user facing functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants