-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
NodejsFunction: External dependecy bundling not working? #26464
Comments
You should be able to use nodeModules instead of externalModules to make the package available on runtime environment without bundling it. |
|
Thanks for the help offered, does this help unblock @rupe120? |
I haven't tried it yet but I think this will resolve my issue. I do feel like the description should be updated to reference the difference between the 2 properties. |
Yes, not listing the desired module in |
|
Describe the bug
I install a module and reference it in
bundling.externalModules[]
and the execution fails with a Module Not Found errorExpected Behavior
Successfully import external module
Current Behavior
With
uuid
both installed and referenced inbundling.externalModules[]
, the following error is produced.Reproduction Steps
Deploy the following app and run the Lambda.
https:/rupe120/cdk-typescript-bundling-dependency-test
Possible Solution
Unknown
Additional Information/Context
No response
CDK CLI Version
2.88.0
Framework Version
No response
Node.js Version
v18.16.1
OS
Windows 11 Enterprise build 22621.1702
Language
Typescript
Language Version
Typescript 5.1.6
Other information
No response
The text was updated successfully, but these errors were encountered: