Jet Versions Save

Jet template engine

v6.2.0

1 year ago

This release

  • fixes a panic occurring when ranging over a channel or other custom rangers without setting the value to variable (#200)
  • speeds up accessing struct fields and eliminates allocations for many uses of resolveIndex() (#201)
  • improves the performance of intsRanger by eliminating allocations (#202)

As a result, it's now possible to execute templates with guaranteed zero memory allocations (during execution) by using a combination of int and custom rangers and either simple field access or custom renderers.

Thank you, @matheusd for submitting these PRs!

Full Changelog: https://github.com/CloudyKit/jet/compare/v6.1.0...v6.1.1

v6.1.0

3 years ago

Added dump() built-in function for development/debugging: https://github.com/CloudyKit/jet/blob/master/docs/builtins.md#dump Thanks @jan-herout for contributing this! (#189)

v6.0.2

3 years ago

Non-breaking workaround for #187: comments were not parsed correctly when using custom delimiters.

v6.0.1

3 years ago

The in-memory template loader introduced in v6.0.0 is now safe for concurrent use. (3f2f52abb7e0d2f6900bf1b7520074b98b4d8e33)

v6.0.0

3 years ago

Version 6 brings Go API improvements, mainly from #182 and #183. Take a look at the breaking changes documentation for a detailed overview. There are no changes to the template language.

v5.1.0

3 years ago

With version 5.1.0, Jet gains whitespace control syntax! The PR is here, and it's explained in the docs here.

v5.0.3

3 years ago

Bugfix release: Concurrent use of a Set of templates could cause data races via a shared array for the argument values of function calls using the reflect package. https://github.com/CloudyKit/jet/commit/0e59615c7a6c1e1046ef26e020eedb01f7fa651f is the only commit since v5.0.2.

v3.0.1

3 years ago

This is just v3.0.0 plus https://github.com/CloudyKit/jet/pull/176. Thanks @tooolbox for the backport!

v5.0.2

3 years ago

Bugfix release: When calling variadic functions, the list of argument expressions was not correctly mapped to the variadic argument slice needed to call the function using reflection. See #171 for more information. Thanks, @alresvor!

v5.0.1

3 years ago

Bugfix release: When using discard syntax in a simple "let" assignment, i.e. one where the right side does not return an optional second value like a map lookup for example, the right side wasn't evaluated. For example, these all worked as expected and the right side was evaluated:

_ := myMap["foo"]
_ = myMap["foo"]

_, ok := myMap["foo"]
_, ok = myMap["foo"]

_ = foo()

But this did not actually execute foo():

_ := foo()

f67efbcea6a7fdd47b716daebca8f9947e86422d fixes this case and is the only commit in v5.0.1 that isn't in v5.0.0.