{{join}} helper

This helper creates a one string from given values, separated by its first argument. Use it to build a string from several values, such as CSS classes separated by spaces. concatenate works the same way without a separator.

Syntax:

{{join separator value1 value2 value3}}

Example:

{{join "," "a" "b" "c" "d"}}

Example output:

"a,b,c,d"

Create your first website with Publii

Join thousands of creators who chose independence. Create content locally and publish lightning-fast, secure websites on your own terms.

Download Publii

Free and open source. Windows, macOS and Linux.

Read the getting started guide