Yaml multiline strings
multiline: >
this will
be a single
line
but this will be a
separate onemultiline: |
these newlines
will be preservedLast updated
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 newlines
The folded style (>) will replace newlines with spaces
(To get a newline using the folded style, use a blank line (two newlines).)
multiline: >
this will
be a single
line
but this will be a
separate onemultiline: |
these newlines
will be preservedThen 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