1.1.1 • Published 5 years ago

get-file-sizes v1.1.1

Weekly downloads
61
License
MIT
Repository
github
Last release
5 years ago

Get File Fizes

This package returns file sizes.

Installation

This is a Node.js module available through the npm registry. Install using the npm install command:

$ npm install get-file-sizes

Usage

CLI

$ node cli.js [folder]

Returns

[ { filePath: 'tests/fixtures/cropped-coffee.jpg',
    size: '129.44KB',
    sizeKb: '129.44KB',
    sizeRaw: 132548 },
  { filePath: 'tests/fixtures/sample.txt',
    size: '867B',
    sizeKb: '0.85KB',
    sizeRaw: 867 } ]
NameTypeDescription
sizestringValue
sizeKbstringValue in Kilobytes
sizeRawnumberValue in bytes

JS

const getFileSizes = require('get-file-sizer');

License

This package is released under the terms of the MIT License.