pub fn to_string(f: impl FnOnce(&mut State<'_>)) -> String