heroku / heroku/heroku-buildpack-nodejs
Unnecessary files in the slug
Open
discussion
enhancement
- Dominant language
- Shell
- Stars
- 1.3k
- Forks
- 2.6k
- Avg merge
- 1d 13h
- Merged PRs (30d)
- 30
Description
Trying to reduce the slug size, I investigated what ends up as part of the 86MB `.heroku/node` folder (as reported by `du -h -d 1 .heroku` in a one-off dyno).
Among this size, we have 6.3MB contributed by `.heroku/node/lib/node_modules/npm/docs`. Including the npm documentation in the slug looks unnecessary to me, and that represents 7% of the (uncompressed) size contributed by the buildpack.
Note that the `man`, `scripts` (containing npm development tooling) and `changelogs` folders of the `npm` install could probably also be removed in the cleanup (but they are much smaller).
Contributor guide
Assessment
This issue has not been assessed yet.