samskivert / jmustache

A Java implementation of the Mustache templating language.
Other
834 stars 128 forks source link

Support for Optional #122

Open bennofs opened 4 years ago

bennofs commented 4 years ago

Right now, it seems that Optional values are always treated as not falsey. I think it would make sense to treat optionals as 1-or-zero element collections. Maybe there should even be automatic chaining for nested selectors? ({{# foo.bar }} where both foo and bar are optionals?)