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

Can @types/node be installed only on development mode? #1474

Closed
Munawwar opened this issue Jul 13, 2022 · 2 comments · Fixed by #1475
Closed

Can @types/node be installed only on development mode? #1474

Munawwar opened this issue Jul 13, 2022 · 2 comments · Fixed by #1475
Assignees
Labels

Comments

@Munawwar
Copy link

Describe the bug

I see @types/node package being installed on yarn install --prod, which does take space on an AWS lambda package zip file (on OSX I see it to be 1.8 MB unzipped, 360 KB zipped).

To Reproduce

  1. rm -fr node_modules
  2. yarn install --prod
  3. Check node_modules directory

Expected behavior

Expected behavior? I don't expect dev dependencies to make its way into production deployments.

Does it matter? since it's just 360 KB?
Well, maybe not the highest priority, but "function" services like AWS lambda is sensitive to deployment package size since it increases cold start. So trimming it down is a good thing.

Code snippets

No response

OS

macOS, linux

Node version

v14.19.1

Library version

8.222.0

API version

NA

Additional context

No response

@yejia-stripe
Copy link
Contributor

Oops not actually closed until we release a new version (sometime later this week!)

@yejia-stripe yejia-stripe reopened this Jul 13, 2022
@yejia-stripe
Copy link
Contributor

Ah, actually it seems like it does need to be in dependencies (see #1274). Going to revert #1475 and close this out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants