pop

Removes the last element from an array and returns array with remaining elements. If an integer is passed as argument, this amount of elements will be removed.

Input:

{{ "John, Paul, George, Ringo" | split: ", " | pop | join: ", " }}

Output:

"John, Paul, George"

Input:

{{ "John, Paul, George, Ringo" | split: ", " | pop: 2 | join: ", " }}

Output: