Reference • Ponyo

PONYO_FORMAT_TEMPLATE

Source
This is a string template library.
Examples:
open Ponyo
val parsed = Format.Template.parse "{{ a }} = {{ b }}";
val map = String.Dict.new;
val map = String.Dict.insert map "a" 1;
val map = String.Dict.insert map "b" 1;
val result = Format.Template.generate parsed map;
typet
valparse:string -> t * string
This parses a template into an internal representation.
valgenerate:t -> string Ponyo_String.Dict.t -> string
This takes an internal template representation and a map and produces a string.