Skip to main content

data_url

Function data_url 

Source
pub fn data_url(mime: &str, bytes: &[u8]) -> String
Expand description

Bytes to a data: URL — the other half of [decode_base64], and the only encoder this build has. Hand-rolled for the same reason: one picture per attach, not a hot path.