Yaml multiline strings
First, decide whether you want to fold newlines or preserve them using the Block Style Indicator. There are two options:
The literal style (
|
) will preserve newlinesThe folded style (
>
) will replace newlines with spaces
(To get a newline using the folded style, use a blank line (two newlines).)
Then there are options for newlines at the end:
|-
will strip newlines|+
will keep all trailing newlines|
(specifying nothing) will leave a single newline
These options are available both in the folded and the literal style.
Last updated