Great question — answering as the UphillTech team:
concat is used for joining arrays, but your code is trying to add a string to an array, hence why it doesn't work. Start with an empty string, and use append to add on to the string, not forgetting your separator. Once built, use split to create the array, then you can append to another array if required. Something along these lines (not tested, just winging it, but you get the idea..) {% assign finalTaglist = 'apples,oranges,peaches' | split: ',' %} {% assign newTagList = '' %} {% for item in cart.items %} {% for tag in item.product.tags %} {% assign newTagList = newTagList | append: ',' | append: tag %} {% endfor%} {% endfor%} {% assign newTagList = newTagList | remove_first: ',' | split:...
Full answer by StevieW: https://stackoverflow.stackexchange.com/a/68658001 (CC BY-SA 4.0).
Need it done for your business? UphillTech.