We are on v6, they are on v8.
https://github.com/harttle/liquidjs/blob/master/CHANGELOG.md
Breaking changes apply to options name changes (no template facing changes here).
Any reason for this not being in the v0.8.0 beta? I mis-read the release notes, and thought it had bumped Liquid to the latest major version, but was actually a minor one. I only ask as I came across an issue, and having certainty about the version used by 11ty (having tried to install the latest major version separately) would help me resolve it.
The reason is that it would break compatibility if anyone is using the options keys that were renamed. See https://www.11ty.io/docs/languages/liquid/#optional%3A-use-your-own-options
Hmm It鈥檚 possible we could shim those鈥擨鈥檒l have to think about it.
@zachleat I think this should just be scheduled with the next major version without shimming it for now.
@zachleat Investigating using my own instance of Liquid, thought it was worth recording the raw build times seen when swapping out the built in version for the latest release.
With builtin LiquidJS instance (6.4.3), 5 runs:
Copied 4 items / Wrote 1463 files in 15.73 seconds (10.8ms each, v0.10.0)Copied 4 items / Wrote 1463 files in 16.11 seconds (11.0ms each, v0.10.0)Copied 4 items / Wrote 1463 files in 15.66 seconds (10.7ms each, v0.10.0)Copied 4 items / Wrote 1463 files in 16.02 seconds (11.0ms each, v0.10.0)Copied 4 items / Wrote 1463 files in 15.80 seconds (10.8ms each, v0.10.0)Average build time: 15.86 seconds
With own LiquidJS instance (9.6.2), 5 runs:
Copied 4 items / Wrote 1463 files in 11.82 seconds (8.1ms each, v0.10.0)Copied 4 items / Wrote 1463 files in 12.06 seconds (8.2ms each, v0.10.0)Copied 4 items / Wrote 1463 files in 11.72 seconds (8.0ms each, v0.10.0)Copied 4 items / Wrote 1463 files in 12.01 seconds (8.2ms each, v0.10.0)Copied 4 items / Wrote 1463 files in 11.82 seconds (8.1ms each, v0.10.0)Average build time: 11.89 seconds (~25% faster)
Seems like some sizeable performance gains to be had for Liquid-based sites!
I will add that v6 is fairly incomplete compared to the official Liquid implementation, with several filters missing (that have since been added to liquidjs) such as where and sort_natural. I just spent the good part of an hour trying to figure out why the latter wasn't working in 11ty, and I feel the incomplete nature of the provided version should at least be made clear in the docs on Liquid templates.
As an FYI (and I know GitHub linked it already), I raised this issue at a high level here: https://github.com/11ty/eleventy/issues/906.
+1 to shimming "strict_filters" to "strictFilters" when bumping up to liquidjs v9 (so that both are supported and we don't break anything).
Lack of sort: "key" (fixed in liquidjs 9.12.0) makes liquid templates a complete no-go for us at the moment.
This shipped on master and will be included with 1.0. @pdehaan I filed your request at https://github.com/11ty/eleventy/issues/1390
馃帀
I鈥檝e updated the dependency again to the latest since the PR #1058 was a little old 馃憤馃徎
Most helpful comment
This shipped on master and will be included with 1.0. @pdehaan I filed your request at https://github.com/11ty/eleventy/issues/1390