array_equal

Compares two arrays. If arrays are equal, returns true.

{% json array_1 %}[1,2,3,4,5]{% endjson %}
{% json array_2 %}[1,2,3,4,5]{% endjson %}
{% assign ar_equal = array_1 | array_equal: array_2 %}

{{ ar_equal | log }}

Above snippet outputs true to logs.

Last updated