All Versions
18
Latest Version
Avg Release Cycle
136 days
Latest Release
-

Changelog History
Page 1

  • v0.15.1 Changes

    πŸ› Bug Fixes

    • πŸ›  Fix bug in LazyValueWrapper, causing it to never resolve.
      David Jennes #328
  • v0.15.0 Changes

    πŸ’₯ Breaking

    • ⬇️ Drop support for Swift < 5. For Swift 4.2 support, you should use Stencil 0.14.2.
      David Jennes #323

    ✨ Enhancements

    • βž• Added support for trimming whitespace around blocks with Jinja2 whitespace control symbols. eg {%- if value +%}.
      Miguel Bejar Yonas Kolb #92 #287
    • βž• Added support for adding default whitespace trimming behaviour to an environment.
      Yonas Kolb #287
    • Blocks now can be used repeatedly in the template. When block is rendered for the first time its content will be cached and it can be rendered again later using {{ block.block_name }}.
      Ilya Puchka #158 #182
    • βž• Added break and continue tags to break or continue current loop.
      Ilya Puchka #175
    • You can now access outer loop's scope by labeling it: {% outer: for ... %}... {% for ... %} {{ outer.counter }} {% endfor %}{% endfor %}.
      Ilya Puchka #175
    • Boolean expressions can now be rendered, i.e {{ name == "John" }} will render true or false depending on the evaluation result.
      Ilya Puchka David Jennes #164 #325
    • πŸ‘ Enable dynamic member lookup using a new DynamicMemberLookup marker protocol. Conform your own types to this protocol to support dynamic member from with contexts.
      Ilya Puchka #219 #246
    • πŸ‘ Allow providing lazily evaluated context data, using the LazyValueWrapper structure.
      David Jennes #324

    πŸ› Bug Fixes

    Internal Changes

    • ⚑️ Updated internal maintenance scripts, and switched to GitHub actions.
      David Jennes #321
    • Made the tokens property on a Template public.
      Stefanomondino #292
    • Made the Template.render(_:) method (that accepts a Context) public.
      David Jennes #322
  • v0.14.2 Changes

    Internal Changes

    • ⚑️ Update Spectre (0.10) and PathKit to support Xcode 13.
      Astromonkee #314
  • v0.14.1 Changes

    πŸ› Bug Fixes

  • v0.14.0 Changes

    August 17, 2020

    πŸ’₯ Breaking

    • ⬇️ Drop support for Swift < 4.2. For Swift 4 support, you should use Stencil 0.13.1.
      David Jennes #294

    ✨ Enhancements

    • βž• Added support for dynamic filter using filter filter. With that you can define a variable with a name of filter , i.e. myfilter = "uppercase" and then use it to invoke this filter with {{ string|filter:myfilter }}.
      Ilya Puchka #203

    πŸ—„ Deprecations

    None

    πŸ› Bug Fixes

    • πŸ›  Fixed using parenthesis in boolean expressions, they now can be used without spaces around them.
      Ilya Puchka #254
    • Throw syntax error on empty variable tags ({{ }}) instead fatalError.
      Ilya Puchka #263

    Internal Changes

  • v0.13.1 Changes

    September 26, 2018

    πŸ› Bug Fixes

    • πŸ›  Fixed a bug in Stencil 0.13 where tags without spaces were incorrectly parsed.
      David Jennes #252
  • v0.13.0 Changes

    September 25, 2018

    πŸ’₯ Breaking

    ✨ Enhancements

    • You can now use parentheses in boolean expressions to change operator precedence.
      Ilya Puchka #165
    • βž• Added method to add boolean filters with their negative counterparts.
      Ilya Puchka #160
    • Now you can conditionally render variables with {{ variable if condition }}, which is a shorthand for {% if condition %}{{ variable }}{% endif %}. You can also use else like {{ variable1 if condition else variable2 }}, which is a shorthand for {% if condition %}{{ variable1 }}{% else %}{{ variable2 }}{% endif %}
      Ilya Puchka #243
    • Now you can access string characters by index or get string length the same was as if it was an array, i.e. {{ 'string'.first }}, {{ 'string'.last }}, {{ 'string'.1 }}, {{ 'string'.count }}.
      Ilya Puchka #245

    πŸ› Bug Fixes

    • πŸ›  Fixed the performance issues introduced in Stencil 0.12 with the error log improvements.
      Ilya Puchka #230
    • Now accessing undefined keys in NSObject does not cause runtime crash and instead renders empty string.
      Ilya Puchka #234
    • for tag: When iterating over a dictionary the keys will now always be sorted (in an ascending order) to ensure consistent output generation.
      David Jennes #240

    Internal Changes

  • v0.12.1 Changes

    August 30, 2018

    Internal Changes

    • ⚑️ Updated the PathKit dependency to 0.9.0 in CocoaPods, to be in line with SPM.
      David Jennes #227
  • v0.12.0 Changes

    August 26, 2018

    ✨ Enhancements

    • βž• Added an optional second parameter to the include tag for passing a sub context to the included file.
      Yonas Kolb #214
    • πŸ‘ Variables now support the subscript notation. For example, if you have a variable key = "name", and an object item = ["name": "John"], then {{ item[key] }} will evaluate to "John".
      David Jennes #215
    • βž• Adds support for using spaces in filter expression.
      Ilya Puchka #178
    • πŸ‘Œ Improvements in error reporting.
      Ilya Puchka #167

    πŸ› Bug Fixes

  • v0.11.0 Changes

    April 04, 2018

    ✨ Enhancements

    • βž• Added support for resolving superclass properties for not-NSObject subclasses.
      Ilya Puchka #152
    • The {% for %} tag can now iterate over tuples, structures and classes via their stored properties.
      Ilya Puchka #172
    • βž• Added split filter.
      Ilya Puchka #187
    • πŸ‘ Allow default string filters to be applied to arrays.
      Ilya Puchka #190
    • Similar filters are suggested when unknown filter is used.
      Ilya Puchka #186
    • βž• Added indent filter.
      Ilya Puchka #188
    • πŸ‘ Allow using new lines inside tags.
      Ilya Puchka #202
    • βž• Added support for iterating arrays of tuples.
      Ilya Puchka #177
    • βž• Added support for ranges in if-in expression.
      Ilya Puchka #193
    • βž• Added property forloop.length to get number of items in the loop.
      Ilya Puchka #171
    • Now you can construct ranges for loops using a...b syntax, i.e. for i in 1...array.count.
      Ilya Puchka #192

    πŸ› Bug Fixes

    • πŸ›  Fixed rendering {{ block.super }} with several levels of inheritance.
      Ilya Puchka #154
    • πŸ›  Fixed checking dictionary values for nil in default filter.
      Ilya Puchka #162
    • πŸ›  Fixed comparing string variables with string literals, in Swift 4 string literals became Substring and thus couldn't be directly compared to strings.
      Ilya Puchka #168
    • Integer literals now resolve into Int values, not Float.
      Ilya Puchka #181
    • πŸ›  Fixed accessing properties of optional properties via reflection.
      Ilya Puchka #204
    • No longer render optional values in arrays as Optional(..).
      Ilya Puchka #205
    • πŸ›  Fixed subscription tuples by value index, i.e. {{ tuple.0 }}.
      Ilya Puchka #172