Skip to content

slice

slice(start, end?): (s) => string

Defined in: Data/Str.ts:186

Extracts a substring between two indices. Data-last: use in pipe.

number

number

(s) => string

pipe("hello", Str.slice(1, 3)); // "el"
pipe("hello", Str.slice(2));    // "llo"