json-field-size
A CLI tool to calculate size of all fields in a json, for memory analysis.
install
yarn global add json-field-size
usage
run json-field-size test.json
┌─────────┬─────┬──────┬───────────┬─────────┐│ (index) │ key │ size │ totalSize │ percent │├─────────┼─────┼──────┼───────────┼─────────┤│ 0 │ 'b' │ 7 │ 29 │ 75.9 ││ 1 │ 'a' │ 17 │ 29 │ 41.4 │└─────────┴─────┴──────┴───────────┴─────────┘
options
key | description |
---|---|
--debug | debug mode |
-h,--help | Print this message. |
-v,--version | Print the version |