# Slice Parser (/placeholders/parsers/slice)



## Aliases [#aliases]

* `slice`, `substr`, `substring`

## Usage [#usage]

`{slice(start):text}` - returns substring from `start` to the end

`{slice(start,end):text}` - returns substring from `start` up to (but not including) `end`

`{slice(start-end):text}` - alternate syntax using a hyphen between indices

## Examples [#examples]

* Input: `{slice(3): Hello World}` → `lo World`
* Input: `{slice(3,7): Hello World}` → `lo W`
* Input: `{slice(3-7): Hello World}` → `lo W`

## Notes [#notes]

* Indices follow typical string-slice semantics (0-based). Negative indices behavior depends on the runtime; prefer positive indices for predictable results.
* Use this parser to extract portions of text or variables.
