jekyll - Does Liquid have a does not contain or not in array operator? -


when calling items , array in liquid template, how call does not contain or not in array?

unless rescue !

create [a, b, c] array.

{% assign input = "a,b,c" | split:"," %} 

unless print if constrain not met.

this prints nothing:

{% unless input contains 'a' %}no a{% endunless %} 

this prints "no z":

{% unless input contains 'z' %}no z{% endunless %} 

Comments

Popular posts from this blog

facebook - android ACTION_SEND to share with specific application only -

python - Creating a new virtualenv gives a permissions error -

javascript - cocos2d-js draw circle not instantly -