githubEdit

$join

Concatenates an array (list) of items into a string.

Signature

{{$join array [path] [separator] [final] }}

Arguments

Name
Description
Type
Required

array

Accepts either an array of data or a relative path, as a String, to an array.

StringString ArrayNumber ArrayObject Array

path

If the array is a collection (an array of objects) then use this path to specify which property in the object should be concatenated.

Default value: ", "

String

separator

String that separates each item in the array.

String

final

The string that's used to separate the last two items.

String

Example #1 - Array of strings

{{$join categories ", " " & "}}

Example #2- Collection (array of objects)

{{$join items "name" ", " " & "}}

Example #3 - Path to array

{{$join "company.employees" "name" ", " " & "}}

Last updated

Was this helpful?