Skip to content

Conversation

@ThiagoTeodoro
Copy link
Contributor

Implements a function to show bytes size with a round way.
With this commit now its possible se values likce 1.2567 GB

Resolve #616

Implements a function to show bytes size with a round way.
With this commit now its possible se values likce 1.2567 GB

Resolve tchiotludo#616
Copy link
Owner

@tchiotludo tchiotludo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image

image

Sorry for late reply, lot of works this times.
Just test the PR and I don't understand why 4 characters after dot ? why not just 3 ?
Maybe use a lib like : https://www.npmjs.com/package/pretty-bytes to display it ?

@ThiagoTeodoro
Copy link
Contributor Author

@tchiotludo i changed for 3 characters after dot.
I don't think we need a lib for this, you have a couple scenarios to use show bytes convert and considering that, it's gonna have more performance with a single function in the client.

@ThiagoTeodoro ThiagoTeodoro requested a review from tchiotludo June 9, 2021 12:16
@tchiotludo tchiotludo merged commit aaf0e9f into tchiotludo:dev Jun 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Show size in bytes in the /topic page

2 participants