Lava Filters - Slice

Category:Text

Description:The slice filter returns a substring, starting at the specified index. An optional second parameter can be passed to specify the length of the substring. If no second parameter is given, a substring of one character will be returned.
Input: "Person": { "SecurityCode": "GX925" }
Lava: First two characters '{{ Person.SecurityCode | Slice: 0, 2 }}' and the last three characters '{{ Person.SecurityCode | Slice: 2, 3 }}'.
Output: First two characters 'GX' and the last three characters '925'.