Skip to content

Releases: osteele/liquid

v1.8.1

27 Feb 04:11

Choose a tag to compare

Performance

  • Template Rendering: ~25% faster, ~54% less memory, ~27% fewer allocations in template rendering benchmarks.
    • Cache compiled scanner regex instead of recompiling per Scan() call
    • Reuse forloop variable map across loop iterations instead of allocating a new map per iteration
    • Add fast paths for string, int, float64, and bool in writeObject, avoiding fmt.Sprint and reflection
    • Reuse expression evaluation context across {{ }} expressions instead of allocating per expression
    • Use stack-allocated array for filter arguments, avoiding heap allocation for filters with ≤4 args
    • Use maps.Copy with pre-sized maps for bindings copies

Fixed

  • String-to-Number Conversion in Arithmetic Filters: Fixed regression where string values from bindings were not converted to numbers in plus, minus, times, and divided_by filters. For example, {{ str_var | plus: 1 }} where str_var = "10" now correctly returns 11 instead of 1. This was introduced in v1.8.0 when filter signatures changed from float64 to any (#124).

Changed

  • Replace custom intMin/intMax helpers with Go 1.21+ min/max builtins.

Tests

  • Expanded test coverage across render, parser, values, filters, and engine packages.

v1.8.0

26 Feb 14:30

Choose a tag to compare

What's Changed

  • Implemented auto-escape functionality and provided a default escape replacer for HTML. by @dop251 in #111
  • Modernize build tooling, fix lint and format errors, and add pre-commit hooks by @osteele in #115
  • Feature/assign dot notation by @osteele in #114
  • feat: add Unicode identifier support with major performance improvements by @uksarkar in #116
  • Compare loop semantics with Ruby implementation by @osteele in #117
  • Issue #85 FRender by @osteele in #118
  • Document security by @osteele in #119
  • Incomplete session description provided by @osteele in #120
  • PR #76 syntax error in assignment statement by @osteele in #122
  • Enhance slice filter with Unicode support and array slicing (#72) by @osteele in #126
  • Fix #109 int to float by @osteele in #124
  • Implement OR operator by @osteele in #127
  • Improve Code Coverage Metrics by @osteele in #132
  • chore: modernize build tooling and lint configuration by @osteele in #133
  • chore: consolidate CI workflows by @osteele in #134
  • fix: run go mod tidy to sync go.mod/go.sum by @osteele in #135
  • feat: add UnregisterTag engine method by @jaime-amate in #130
  • feat: support int and numeric string timestamps in date filter by @osteele in #137
  • feat: add LaxFilters option for undefined filter handling by @osteele in #139
  • ci: add generated file freshness check by @osteele in #138
  • fix: resolve gosec G703 lint error in CLI by @osteele in #140

New Contributors

Full Changelog: v1.7.0...v1.8.0

v1.7.0

01 Jun 16:19

Choose a tag to compare

What's Changed

New Contributors

Full Changelog: v1.6.0...v1.7.0

v1.6.0

06 Nov 12:36
f432a25

Choose a tag to compare

What's Changed

New Contributors

Full Changelog: v1.5.2...v1.6.0

v1.5.2

19 Oct 09:00
fe7cf84

Choose a tag to compare

What's Changed

  • Count number of characters in size filter instead of number of bytes by @jamslinger in #101
  • Don't panic in when slicing with index out of bound by @jamslinger in #99

Full Changelog: v1.5.1...v1.5.2

v1.5.1

18 Oct 15:23
71b8fa2

Choose a tag to compare

What's Changed

  • Don't panic in filter divided_by on division by zero by @jamslinger in #97

Full Changelog: v1.5.0...v1.5.1

v1.5.0

17 Oct 16:32
cc7bda4

Choose a tag to compare

What's Changed

New Contributors

Full Changelog: v1.4.0...v1.4.1

v1.4.0

26 Apr 11:16
f9950df

Choose a tag to compare

What's Changed

  • Add FRender to allow rendering into a custom io.Writer by @jamslinger in #86

New Contributors

Full Changelog: v1.3.3...v1.4.0

v1.3.3

25 Apr 08:17
2b89126

Choose a tag to compare

What's Changed

  • Added code to respect whitespace trimming flags by @chrisghill in #78

New Contributors

Full Changelog: v1.3.2...v1.3.3

v1.3.2

24 Sep 20:25
5dfb339

Choose a tag to compare

What's Changed

  • Allow range expression as general expressions (not only loops) by @aisbergg in #65

Full Changelog: v1.3.1...v1.3.2