4 ms·
A note on your edit: The difference you observed is not because of du. Your node_modules really does take 673 MB on disk. File systems divide the disk into seg
by mdavidn 11y ago
A note on your edit: The difference you observed is not because of du. Your node_modules really does take 673 MB on disk.
File systems divide the disk into segments, confusingly also called blocks. Only one file may occupy a block. On my Mac, the block size is 4 KB, so a file containing a single byte will still occupy 4 KB on disk. The du utility reports the latter. The Mac Finder reports the former in column view and both in the "Get Info" pane.
Unpacked NPM modules have many, many small files, obviously.
- tlrobinson 11y agoAh, interesting, thanks.