Repository navigation
Description
I don't think this has security impact. This is a Golden Liquid conformance report, and I'm happy to split it or send PRs. Tested npm [email protected] and main af9b02d58612e4f739300f8067b584d291e426c1 with default options. Data is {}; outputs are Golden/LiquidJS.
Filters (6 cases; Golden sections blank_and_empty, filters/default, filters/replace, filters/round). Golden requires nil == blank, allow_false before fallback, undefined replacement as empty, and integer round precision. LiquidJS compares EmptyDrop as false, rejects argument order, uses split/join, and rounds fractions. {% if nil == blank %}TRUE{% else %}FALSE{% endif %} -> TRUE/FALSE (blank_and_empty:nil is equal to blank); {{ 5.666 | round: 1.2 }} -> 5.7/5.666 (filters/round:argument is a float).
Nested comments (2 cases). Shopify allows nesting; LiquidJS stops at the first endcomment. {% comment %}{% comment %}x{% endcomment %}{% endcomment %} -> empty/ParseError (tags/comment:nested comment blocks); {% comment %}{% comment %}{% if true %}x{% endif %}{% endcomment %}{% endcomment %} -> empty/ParseError (tags/comment:nested comment blocks, with nested tags).
Named cycles (4 cases). Golden keeps a named counter across lists; LiquidJS keys state by candidates. {% cycle 'a': 1, 2 %}{% cycle 'a': 7, 8 %} -> 18/17 (tags/cycle:named with different items); {% cycle a: '1', '2' %}{% cycle a: '1', '2', '3' %}{% cycle a: '1' %} -> 12/111 (tags/cycle:named with different number of arguments).
Loops and tablerow (9 cases). LiquidJS slices modifiers and misses break in its row loop. {% for i in (0..3) offset: -2 %}{{ i }} {% endfor %} -> 0 1 2 3/2 3 (tags/for:range loop, negative offset); {% tablerow n in (1..3) cols:2 %}{{n}}{% break %}{{n}}{% endtablerow %} -> one row/two rows (tags/tablerow:break from a tablerow loop).
Remaining jg-rp/golden-liquid cases:
blank_and_empty:null is equal to blankfilters/default:false keyword argument before positionalfilters/default:true keyword argument before positionalfilters/replace:undefined first argumenttags/cycle:named with growing number of argumentstags/cycle:named with shrinking number of argumentstags/for:range loop, negative offset, continuetags/for:range loop, negative offset, limittags/for:range loop, negative offset, negative limittags/for:range loop, offset, negative limittags/tablerow:negative offsettags/tablerow:negative offset and limittags/tablerow:break from a tablerow loop inside a for loop
Activity