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

add field sizeOnDisk? #23

Open
vogler opened this issue Aug 29, 2023 · 1 comment
Open

add field sizeOnDisk? #23

vogler opened this issue Aug 29, 2023 · 1 comment

Comments

@vogler
Copy link

vogler commented Aug 29, 2023

It would be nice to have another field that shows the size on disk of a package in node_modules as there can be quite big differences:

$ howfat picocolors
picocolors@1.0.0 (5.52kb, 7 files, ©ISC)
$ du -sh node_modules/picocolors
28K	node_modules/picocolors

https://www.npmjs.com/package/picocolors shows 5.66kB for 'Unpacked Size' - I don't know what data howfat uses.

This is of course only possible if the package is installed locally.
The size on disk could be shown by default when running

  • howfat . and ./node_modules exists, or
  • howfat x and ./node_modules/x exists.
@megahertz
Copy link
Owner

I have no plans for that at least in the near future.

That's a good point about different size in howfat and on npm. Actually, howfat divides size by 1024. It would be nice to use 1000 bytes per kilobyte or use "kib" instead of "kb" in the output, I haven't decided yet which option is better.

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

No branches or pull requests

2 participants