#ascii #ansi #unicode #terminal #cli #data-structures

borderrs

为您的文本和数据结构添加时尚的边框

2 个版本

0.1.1 2023年3月23日
0.1.0 2023年3月23日

#1937 in 文本处理

Apache-2.0

19KB
216

borderrs

Crates.io Documentation dependency status

此 crate 允许用户以更美观的方式格式化许多数据结构。

维基百科关于 框绘制字符 的页面非常有帮助

目前,我们支持

使用示例

use borderrs::{styles::THIN, BorderFormatter};

let slice = [0, 1, 2, 3, 4];
println!("{}", THIN.format_slice(&slice));

let mut map = HashMap::default();
map.insert("Jon", 38);
map.insert("Jake", 25);
map.insert("Josh", 17);
println!("{}", THIN.format_hash_map(&map));

println!("{}", THIN.format_display("hello"));
println!("{}", THIN.format_debug("hello"));

无运行时依赖