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: avoid dynamic requires #113

Closed
wants to merge 1 commit into from
Closed

Conversation

BDav24
Copy link

@BDav24 BDav24 commented Oct 1, 2020

Avoid dynamic requires to be able to bundle projects in one file (with parcel build index.js --bundle-node-modules for example). Can be useful for lambda functions.

Avoid dynamic requires to be able to bundle projects in one file (with `parcel build index.js --bundle-node-modules` for example). Can be useful for lambda functions.
@evanw
Copy link

evanw commented Oct 24, 2020

FWIW this PR would also make logform usable with the esbuild bundler too.

This PR removes the lazy evaluation aspect so it's not equivalent to the current code. However, you can avoid dynamic require while still keeping the lazy evaluation aspect if you would like. See evanw/esbuild#480 (comment) for an example of how to do this.

@RomanHotsiy
Copy link

This looks like a pretty safe change but a major blocker for some folks.

@DABH Is there anything we can help with to get this merged?

@blimmer
Copy link
Contributor

blimmer commented Dec 9, 2020

I created #117 , which retains the lazy behavior

@BDav24
Copy link
Author

BDav24 commented Mar 24, 2021

Closed in favor of #117

@BDav24 BDav24 closed this Mar 24, 2021
@BDav24 BDav24 deleted the patch-1 branch March 24, 2021 15: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.

4 participants