aws / aws/aws-cdk

aws_lambda_nodejs: add option to visualize the esbuild bundle size

Open
#28,087 2 comments 1 reaction 0 assignees View on GitHub
@aws-cdk/aws-lambda-nodejs effort/medium feature-request p2
Dominant language
TypeScript
Stars
12.9k
Forks
4.6k
Avg merge
2d 3h
Merged PRs (30d)
83

Description

### Describe the feature

It will be nice to visualize the esbuild bundle and optionally open it after every build.

### Use Case

Keeping an eye on dependency size as it influences performance

### Proposed Solution

You can see an example of doing it [here](https://github.com/rehanvdm/lambda-template/pull/1/files#diff-04d2b6fafaa8b5cda9a27152003bb174d134e4726449fa36c9dbfe78e146c8deR81) the result looks like:
![image](https://github.com/aws/aws-cdk/assets/22810856/df017561-265a-406a-9976-ed019f2bcf08)

### Other Information

_No response_

### Acknowledgements

- [X] I may be able to implement this feature request
- [ ] This feature might incur a breaking change

### CDK version used

-

### Environment details (OS name and version, etc.)

-

Contributor guide

Open the contributing guide

Research direction

Start by locating the aws_lambda_nodejs construct and its esbuild build entry point; the issue does not name specific files or tests. Review the linked example for the expected bundle visualization, then determine how to make it optional and whether it can open after every build. Done means the bundle size can be visualized and opening it is opt-in.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, typescript
Domain
build-system
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.