-
Notifications
You must be signed in to change notification settings - Fork 154
Add support for --external to esbuild configuration #340
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
Conversation
chore: Merge develop into master for 1.8.1 Release
chore: Lambda Builder 1.9.0 Release Merge to Master
release: 1.10.0
release: 1.11.0
chore: Merge develop into master
chore: Merge develop into master
chore: Merge develop into master
| args.append("--minify") | ||
| if sourcemap: | ||
| args.append("--sourcemap") | ||
| if len(externals) > 0: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very minor comment, but can we make this if externals: to be consistent with PEP8 styling guide?
mndeveci
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@chris-armstrong thanks for the PR! Can you address the concern from @mildaniel? Other than that, LGTM.
The code uses ‘if externals:’ now - was there anything else? |
mndeveci
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@chris-armstrong thanks for the PR! Can you address the concern from @mildaniel? Other than that, LGTM.
The code uses ‘if externals:’ now - was there anything else?
Sorry my bad!
|
@chris-armstrong one last thing. This PR was pointing to master branch. I now changed it to develop, but it is out of date now. Can you re-base your changes from develop so that we can merge into? If you want, you can close this PR and open a new one, which should branch out from develop. |
|
I can, but I’ll be away from my computer for the next few days so I won’t be able to rebase immediately |
I've opened #353 that has been rebased against develop |
|
@chris-armstrong .. should we close this PR? |
Yes I'll close this now |
This PR adds support to the esbuild
BuildPropertiesto specify a set of externals to use when building a source code bundle. This is useful when the package you require is on a layer and cannot be bundled with esbuild. It converts an array ofExternalsto a set ofesbuild--external:<module>parameters.For example, if your
BuildPropertiescontains:Then
--external:aws-sdk --external:puppeteerwill be added to the esbuild command line.(Please forgive any non-idiomatic Python code - this is the first time writing Python for a number of years so I'm rusty on latest best practice).
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.