You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We need to create a function that will format the byte sizes that are returned from the API. We can also utilize the JS Intl.NumberFormat() API to help us out here, see list of possible units here.
The basic logic for this function is as follows:
Size is less then 1 Kb
Display size in bytes
Size is less then 1 Mb
Display size in kilobytes
Size is less then 1 Gb
Display size in megabytes
The text was updated successfully, but these errors were encountered:
We need to create a function that will format the byte sizes that are returned from the API. We can also utilize the JS Intl.NumberFormat() API to help us out here, see list of possible units here.
The basic logic for this function is as follows:
The text was updated successfully, but these errors were encountered: