All Versions
Latest Version
Avg Release Cycle
93 days
Latest Release
1444 days ago

Changelog History
Page 1

  • v0.10.0 Changes

    June 30, 2020

    ๐Ÿ“š After 5 months of development, I'm happy to announce the availability of version 0.10 of Askama, the type-safe, compiled Jinja-like template engine for Rust. The major (breaking) change in this release is that the framework integrations, which were previously included in the main crate behind feature flags, have now been moved into 4 separate crates; a new integration with the warp web framework is also shipped in a separate askama_warp crate. If you use an integration, you should now only depend on the integration crate, which re-exports content from the askama crate as well as any integration symbols. Finally, @cetra3 has created a book book which should make navigating the documentation much better.

    โฌ†๏ธ Upgrade notes:

    • Move integration code into askama_actix, askama_gotham, askama_iron and askama_rocket crates
    • โšก๏ธ Update Gotham integration to version 0.4

    Other changes:

    • ๐Ÿ“š Move documentation into a new book (#332, thanks to @Cetra)
    • โž• Add integration for the warp web framework, as an askama_warp crate (#290, thanks to @aeons)
    • ๐Ÿ‘ Allow blocks to be nested inside if, for and match blocks (#336)
    • ๐Ÿ‘Œ Support for function calls (#304, thanks to @Senzaki)
    • โž• Add urlencode filter (#305, thanks to @jxs)
    • 0๏ธโƒฃ Disable default features in many dependencies to limit the size of the transitive dependency set
    • ๐Ÿ›  Fix panic in truncate filter (#296, thanks to @danloh)

    Thanks to @paolobarbolini, @brunobell, @cipriancraciun, @kyrias, @jeromegn, @NilsIrl and @DusterTheFirst for additional improvements.

  • v0.9.0 Changes

    February 24, 2020

    ๐Ÿš€ After 11 months of development, I'm happy to announce the availability of version 0.8 of Askama, the type-safe, compiled Jinja-like template engine for Rust. This has been a long release cycle; mostly I've spent quite a bit of time trying to figure out problems with how to manage Askama's built-in integrations. In the end, 0.9.0 shipped with the integrations problems unsolved, but they were solved shortly thereafter.

    โฌ†๏ธ Upgrade notes:

    • ๐Ÿšš Move no-receiver size_hint() method to a separate trait (#270, thanks to @jbg)
    • โฌ†๏ธ Upgrade Actix-Web integration to Actix-Web 2.0 (#286, thanks to @DCjanus)
    • 0๏ธโƒฃ Default Actix-Web and Gotham integrations to UTF-8 (#219, thanks to @spease)

    Other changes:

    • โž• Add basic support for {% raw %} blocks (#231, thanks to @fokinpv)
    • ๐Ÿ‘ Allow referencing self as a variable (fixes #207)
    • โž• Add support for boolean literals (#265, thanks to @davebrent)
    • โž• Add support for character literals (#283, thanks to @siiptuo)
    • ๐Ÿ‘Œ Support escaping in string literals (#287, thanks to @siiptuo)
    • ๐Ÿ‘Œ Improve interface for askama_escape (#243, thanks to @quadrupleslap)
    • ๐Ÿ‘ Allow Rust macro calls in more places (#226)
    • ๐Ÿ›  Fix a regression in partial inheritance (#224)
    • ๐Ÿ‘Œ Improvements to the Actix-Web integration (#223, thanks to @DoumanAsh)
    • ๐Ÿ“š Clarify documentation on filter precedence (#230, thanks to @notsimon)
    • โž• Add documentation on how to deal with recursive data types (#235, thanks to @drahnr)
    • โž• Add documentation on nesting Template types (#218, thanks to @victe)
    • ๐Ÿ‘Œ Improve documentation for Actix-Web and Gotham integrations (#250, thanks to @bardiharborow)
    • โฌ†๏ธ Upgrade to nom 5 and non-macro parser combinators
    • โฌ†๏ธ Upgrade to syn/quote/proc_macro2 version 1.0

    Thanks to @kazimuth and @bardiharborow for additional internal improvements.

  • v0.8.0 Changes

    February 20, 2019

    ๐Ÿš€ After 3 months of development, I'm happy to announce the availability of version 0.8 of Askama, the type-safe, compiled Jinja-like template engine for Rust -- all the more so because it has taken me way too long to push out this release due to an exceedingly busy period in my personal life.

    ๐ŸŽ Askama 0.8 is up to 2 times as fast as 0.7.2, thanks to performance improvements contributed by @botika and @yossyJ. For comparisons to other template engines, please look at the template benchmarks repo. The largest feature this time around is the newly added support for pluggable escape engines and formats. By adding just a few lines to the askama.toml configuration file and writing a simple implementation of the Escaper trait, Askama can use custom code for escaping, such as for different formats (LateX or shell) or with even more optimized performance (using SIMD).

    โฌ†๏ธ Upgrade notes:

    • ๐Ÿ— The use of build scripts is no longer needed and has been deprecated (#199, thanks to @de-vri-es)
    • โฌ†๏ธ Upgraded the Rocket integration to Rocket 0.4
    • Template::extension() is now a static method (#127, thanks to @ubnt-intrepid)
    • ๐Ÿ—„ Use of the _parent field is now deprecated (thanks to @botika)

    Other changes:

    • โฌ†๏ธ Upgraded the Rocket integration to Rocket 0.4
    • โž• Added optional support for Gotham integration (#177, thanks to @rakenodiax)
    • โž• Added an into_response() method for actix-web users (#205, thanks to @ZizhengTai )
    • โž• Add support for tuple destructuring in let and for blocks (#187, thanks to @yossyJ)
    • โž• Added optional yaml filter (#192)
    • โž• Added an indent filter (#131, thanks to @casey)
    • โž• Added isize and f64 filters (#146, thanks to @tizgafa)
    • โž• Added a filesizeformat filter (#161, thanks to @tizgafa)
    • โž• Added support for the loop.last variable (#194, thanks to @yossyJ)
    • ๐Ÿ‘ Allow matching enum struct variants (#182, thanks to @mcarton)
    • ๐Ÿ‘ Allow templates to work without importing Template directly (#147, thanks to @ubnt-intrepid)
    • ๐Ÿ‘ Allow referencing self in expressions (#207)
    • ๐Ÿ›  Fixed problems with unescaped expressions (#107 and #132)
    • ๐Ÿ›  Fixed off-by-one error in escaping function (#138, thanks to @benjunmun)
    • Send debug output to stderr instead of stdout
    • Document assignment using {% let %} blocks
  • v0.7.2 Changes

    October 08, 2018

    ๐Ÿš€ After two months, I'm happy to announce the 0.7.2 release of Askama, the type-safe, compiled Jinja-like template engine for Rust! Despite the small version number increase (because this release should be fully backwards compatible with earlier 0.7 releases), there's a good amount of feature in this release. Happily, I can say that for the first time, all of the improvements in this release are due to @botika spending a lot of time on improving Askama over the past months, for which I owe them many thanks! Let's dive in:

    • ๐Ÿ“š Custom syntax support: in response to a bug reporter who wanted to generate LaTeX with Askama (#121), it is now possible to use custom block delimiters in your Askama templates. Read the documentation for more information on how to define and use custom syntaxes. Thanks to @botika for spending a lot of time on getting this just right.
    • โž• Added a number of built-in filters: abs, capitalize, center and wordcount
    • ๐Ÿ›  Fixed support for range-based for-loops (#117) by specializing the code generator
    • ๐Ÿ›  Fixed operator precedence issues with loop attributes (like index)
    • ๐Ÿ›  Fixed a number of edge cases in macro scope resolution
  • v0.7.1 Changes

    July 23, 2018

    ๐Ÿ“š Some nice new features are now available as part of Askama 0.7.1. The most important one is the ability to search multiple directories for template files. This works by adding an askama.toml file to the crate root and specifying the search directories in there (see the documentation). Now that there is a configuration mechanism, this may unlock other potential features that rely on some way to specify out-of-band configuration.

    ๐Ÿš€ This release also adds optional support for actix-web. If you enable the with-actix-web feature, Template derives will include an impl for actix-web's Responder trait, so that you can trivially return template context structs from actix-web handlers.

    • โž• Add support for multiple template directories (thanks to @mashedcode)
    • โž• Add impl for actix-web Responder trait (thanks to @ryanmcgrath)
    • โž• Add linebreaks and linebreaksbr filters (thanks to @Aaronepower)
    • ๐Ÿ‘ Allow Template users to inspect template extension() (thanks to @ryanmcgrath)
    • derive(Template) is no longer restricted to named field struct types
  • v0.7.0 Changes

    June 25, 2018

    ๐Ÿš€ I'm excited to announce a new release of Askama, the type-safe, compiled Jinja-like template engine for Rust. Among other things, this is what actix-web uses in their TechEmpower benchmarks. Note that this release relies on Rust features first released in 1.26.0.

    ๐Ÿš€ The most interesting new feature in this release is an overhauled inheritance model:

    • ๐Ÿ‘ _parent fields are no longer needed (but still supported for compatibility)
    • ๐Ÿ‘Œ Supported for multi-layer inheritance has been implemented
    • Blocks can now be defined inside other blocks
    • The super() macro can be used to call parent blocks from inside a block
    • โœ‚ Removes the need for elaborate imports for inheritance across modules
    • ๐Ÿ›  Fixes some issues with extends paths on Windows

    ๐Ÿš€ For this release I finally spent some time collecting benchmarks for template engines. The results can be found in this GitHub repository. I was happy to see that Askama performance seems more than competitive compared to popular alternatives.

    ๐Ÿš€ Smaller improvements in this release:

    • โž• Add support for Range expressions (a..b; see #95)
    • โž• Add support for Index operation (a[b]; see #95)
    • ๐Ÿ‘ Allow methods to be called on self
    • โž• Add support for loop.first variable
    • โž• Add a simple truncate filter (see #95)
    • ๐Ÿ›  Matching is more robust thanks to match binding modes (fixes #94)
    • ๐Ÿ”€ askama::Error is now Send + Sync + 'static
    • ๐Ÿ›  Renamed lifetime on Rocket integration to prevent conflicts (fixes #88)
    • โฌ†๏ธ Upgrades to nom 4, syn 0.14 and quote 0.6

    ๐Ÿš€ Thanks to @Smibu and @dathinab for contributing code to this release, and to everyone else who submitted feedback for their support in further improving Askama.

    ๐Ÿšง I recently started a Patreon page. If you are in a position to support ongoing maintenance and further development of Askama or use it in a for-profit context, please consider supporting my work!

  • v0.6.4 Changes

    April 30, 2018
    • โž• Added support for unary operators ! and - (fixes #83)
  • v0.6.3 Changes

    April 30, 2018

    ๐Ÿ›  Fixed a regression introduced in 0.6.2 with interacting filter expressions and statements.

  • v0.6.2 Changes

    April 18, 2018

    ๐Ÿš€ Some great bug reports came in after the 0.6.0 and 0.6.1 releases last week, which I fixed:

    • ๐Ÿ›  Fixed problems with using nested filter (or macro) calls in expressions (#78)
    • โž• Add documentation and tests for comments, after an issue with whitespace surrounding comments was found (#79)
  • v0.6.1 Changes

    April 18, 2018

    ๐Ÿ›  This is a quick bugfix release for #73: due to an unsupported way of including syn, Askama had a run-time dependency on proc-macro, which didn't work well in some scenarios. Thanks to @dtolnay for the bug fix.