mirror of
https://gitlab.com/arnekeller/ascii-table.git
synced 2024-12-04 13:39:06 +00:00
Updated example
This commit is contained in:
parent
1fd3fc0383
commit
c9b4955773
@ -5,11 +5,11 @@ Print ASCII tables to the terminal.
|
||||
## Example
|
||||
|
||||
```
|
||||
use ascii_table::{TableConfig, print_table};
|
||||
use ascii_table::AsciiTable;
|
||||
|
||||
let config = TableConfig::default();
|
||||
let ascii_table = AsciiTable::default();
|
||||
let data = vec![&[1, 2, 3], &[4, 5, 6], &[7, 8, 9]];
|
||||
print_table(data, &config);
|
||||
ascii_table.print(data);
|
||||
// ┌───┬───┬───┐
|
||||
// │ 1 │ 2 │ 3 │
|
||||
// │ 4 │ 5 │ 6 │
|
||||
|
Loading…
Reference in New Issue
Block a user