Correct usage of fmt

I’m trying to learn how to use fmt, is there any examples which are good to look at?

I’m specifically looking to try and use the vbox etc features.

I’ve poked around at it and mostly worked out how to generate specific formatters for single values, however doing I can’t work out how to combine them.

fmt is a combinator library exposing the functionality of the Format module. A nice introduction to the latter be found at http://caml.inria.fr/resources/doc/guides/format.en.html.

Cheers,
Nicolás

3 Likes

A more recent url for that introduction is:

https://ocaml.org/learn/tutorials/format.html

Note that it is mentioned as “required reading” in the Fmt documentation ;–)

4 Likes

Hi, thanks for those links, I had attempted to read both of those previously and completely missed the point… :slight_smile:

More reading has however now cleared it all up!

1 Like