From e96dfe0604d398aff2da4e723e1f200d62e929ca Mon Sep 17 00:00:00 2001 From: Vitalii Oliinyk Date: Wed, 22 Oct 2025 15:18:03 +0300 Subject: [PATCH 1/2] Add `prepend_to_array` filter documentation to Liquid filters This update introduces documentation for the `prepend_to_array` filter, which allows users to prepend elements to an existing array in Liquid. The new section includes usage examples and rendered output to enhance understanding and usability. --- source/campaigns/editor/filters.rst | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/source/campaigns/editor/filters.rst b/source/campaigns/editor/filters.rst index d68b298fe..55ee71821 100644 --- a/source/campaigns/editor/filters.rst +++ b/source/campaigns/editor/filters.rst @@ -114,6 +114,28 @@ Rendered Liquid |hr| +prepend\_to\_array +................. + +Prepends elements to an existing array. + +Liquid + +.. code-block:: liquid + + {% assign my_array = "" | new_array: "element1", "element2" %} + {% assign my_array = my_array | prepend_to_array: "element3" %} + + Array: {{ my_array | json }} + +Rendered Liquid + +.. code-block:: text + + Array: ["element3","element1","element2"] + +|hr| + asset\_url .......... From 4f2d65a3e4b3912455e2739b9b9fd4bcc3d96b22 Mon Sep 17 00:00:00 2001 From: Vitalii Oliinyk Date: Wed, 22 Oct 2025 16:07:37 +0300 Subject: [PATCH 2/2] Update `prepend_to_array` filter documentation in Liquid filters This commit moves the documentation for the `prepend_to_array` filter to a more appropriate section within the Liquid filters documentation. The section includes usage examples and rendered output to improve clarity and usability for users looking to prepend elements to an existing array. --- source/campaigns/editor/filters.rst | 44 ++++++++++++++--------------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/source/campaigns/editor/filters.rst b/source/campaigns/editor/filters.rst index 55ee71821..d3a9d26cb 100644 --- a/source/campaigns/editor/filters.rst +++ b/source/campaigns/editor/filters.rst @@ -114,28 +114,6 @@ Rendered Liquid |hr| -prepend\_to\_array -................. - -Prepends elements to an existing array. - -Liquid - -.. code-block:: liquid - - {% assign my_array = "" | new_array: "element1", "element2" %} - {% assign my_array = my_array | prepend_to_array: "element3" %} - - Array: {{ my_array | json }} - -Rendered Liquid - -.. code-block:: text - - Array: ["element3","element1","element2"] - -|hr| - asset\_url .......... @@ -977,6 +955,28 @@ Available options: |hr| +prepend\_to\_array +.................. + +Prepends elements to an existing array. + +Liquid + +.. code-block:: liquid + + {% assign my_array = "" | new_array: "element1", "element2" %} + {% assign my_array = my_array | prepend_to_array: "element3" %} + + Array: {{ my_array | json }} + +Rendered Liquid + +.. code-block:: text + + Array: ["element3","element1","element2"] + +|hr| + probability\_by ...............