Registry / utility / byte-unit

byte-unit

JSON →
library5.2.3rscratesunverified

A library for interacting with units of bytes.

# Cargo.toml [dependencies] byte-unit = "5.2.3"
INSTALL
IMPORT
SIG · BYTE-UNIT
B
byte-unit
utilityrustv5.2.3
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Byte
use byte_unit::Byte;

Creates a Byte from bytes and converts to human-readable unit.

use byte_unit::Byte; let byte = Byte::from_bytes(1024); assert_eq!(byte.get_appropriate_unit(true).to_string(), "1 KiB");
Debug
Known issues

No known issues recorded.

Upgrade
Version history
5.2.3latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
4 hits · last 30 days
node
4
Resources
byte-unit — cargo add byte-unit · libregistry