我正在尝试使用Liquid语法从对象列表创建数组:
{% for operation in menuItems %}
{% assign words1 = operation.Title | split: '_' %}
{% assign controllerName = words1 | first %}
{% assign controllersTmp = controllersTmp | append: '_' | append: controllerName %}
{% endfor %}
我想把controllersTmp
分割以获得我的数组,但此时我的controllersTmp
为空。
有什么帮助吗?
concat
。 - Nicolas R