bdarcus / csln

Reimagining CSL
Mozilla Public License 2.0
12 stars 0 forks source link

Formatting functions, crates #55

Open bdarcus opened 1 year ago

bdarcus commented 1 year ago

Rather than writing myself, would be good if I could find some crates that do stuff like:

https://github.com/vixalien/written/blob/6c4833d1786ca1979033ef1076dedc73ff0f6b4d/written.ts#L244

Come to think of it, maybe better to split off an EDTF date formatting module.

names

fn main() {
    let names = ["Sam", "Jane", "Dan", "Maria"];
    let max = 2;
    let short_names: Vec<_>  = names.iter().take(max).collect();
    print!("{:?}", short_names);
}

...