Reconcile the differences between numberToHumanSize and number_to_human_size (KB vs KiB, significant digits)
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
The following discussion from !99198 (merged) should be addressed:
-
@mkozono started a discussion: nitpick (non-blocking): There is a preexisting typo
precicion=>precision.Apparently
precisiondefaults to3andsignificantdefaults totrue, therefore the preexisting behavior is actually "3 significant digits". Do we just want this?= number_to_human_size(@total_size)question (non-blocking): There seem to be a number of self-contradictions and differences with
number_to_human_sizeinnumberToHumanSize. WDYT about a follow up issue/MR to reconcile them?For example if I'm reading it right, Rails outputs
12.1 KB, while the JS outputs12.10 KiB.
Edited by 🤖 GitLab Bot 🤖