Jinja2 C++ (and for C++) almost full-conformance template engine implementation
ToJson
filter implementation based on boost::json (rapidjson seems to become abandoned)Full Changelog: https://github.com/jinja2cpp/Jinja2Cpp/compare/1.2.1...1.3.0-beta
Changes and improvements
Fixed bugs
Breaking changes
Changes and improvements
Fixed bugs
Breaking changes
batch
filter added (#150)slice
filter added (#141)format
filter added (#145)tojson
filter added (#142)striptags
filter added (#177)center
filter added (#179)xmlattr
filter added (#143)raw
/endraw
tags added (#148)'a' * 5
will produce 'aaaaa'
) (#162)meta
/endmeta
tags) added (#107)-fPIC
flag added to Linux build configurationJINJA2CPP_BUILD_SHARED
flag added in order to build shared version of Jinja2C++ libraryblock
content if child doesn't override this block (#161)variant
, string_view
and optional
default
attribute added to the map
filter (#48)GenericList
type (#66)Value
filter
tag support added to the template parser (#44)escape
filter support added to the template parser (#140)capitalize
filter support added to the template parser (#137)set
tag added to the parser (#45)loop.depth
and loop.depth0
variables support addedTemplateEnv
TemplateEnv
added*context
special param|
) operator precedence (#47)endblock
taginclude
and for
tagsinclude
, import
and from
statements implemented. Now it's possible to include other templates and use macros from other templates.with
statement implementeddo
statement implementedRenderAsString
method now returns nonstd::expected
instead of regular std::string
import
, extends
and include
generate errors if parsed without TemplateEnv
setexternal
dependency management mode by default