2 releases

0.1.1 May 17, 2023
0.1.0 May 17, 2023

#11 in #stupid

Download history 27/week @ 2024-07-22 19/week @ 2024-07-29 22/week @ 2024-08-05 7/week @ 2024-08-12 12/week @ 2024-08-19 44/week @ 2024-08-26 8/week @ 2024-09-02 12/week @ 2024-09-09 29/week @ 2024-09-16 56/week @ 2024-09-23 9/week @ 2024-09-30 9/week @ 2024-10-07 19/week @ 2024-10-14 4/week @ 2024-10-21 11/week @ 2024-10-28 18/week @ 2024-11-04

52 downloads per month
Used in 8 crates (3 directly)

AGPL-3.0

3KB

format_table

Format tables with a stupid API. Documentation.

Example:

let mut table = vec!["product\tquantity\tprice".to_string()];
for (p, q, r) in [("tomato", 12, 15), ("potato", 10, 20), ("rice", 5, 12)] {
	table.push(format!("{}\t{}\t{}", p, q, r));
}
format_table::format_table(table);

lib.rs:

Format tables with a stupid API.

Example:

let mut table = vec!["product\tquantity\tprice".to_string()];
for (p, q, r) in [("tomato", 12, 15), ("potato", 10, 20), ("rice", 5, 12)] {
    table.push(format!("{}\t{}\t{}", p, q, r));
}
format_table::format_table(table);

A table to be formatted is a Vec<String>, containing one string per line. Table columns in each line are separated by a \t character.

No runtime deps