Boost logo

Boost :

From: Peter Dimov (pdimov_at_[hidden])
Date: 2023-02-07 16:32:50


Andrzej Krzemienski wrote:
> These are described here: https://github.com/mustache/spec
>
>
> Thanks.

...

> Ok, so this explains what Boost.Mustache does today. But on a higher level,
> does the *specification* for mustache templates require that data is in the
> JSON format? The examples in the web show JSON as the source of data.
> Boost.Mustache says about everything convertible to json::value.
>
> It looks like the JSON input is a must. But I can see no formal specification for
> this. In fact, is there a one "source of truth" about mustache templates?

Yes, https://github.com/mustache/spec. Since all reference input data is in
JSON format, it follows that JSON is the canonical data source for Mustache.

> This is what I would expect. And apparently you also. But are you explaining
> your implementation or the "formal specification" of mustache templates?

Again, the "formal specification" at https://github.com/mustache/spec says
this is how it works.

This part specifically is in https://github.com/mustache/spec/blob/master/specs/sections.yml.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk