How to define string `" foo\n bar\n "` in one `""" ... """` block?

I don’t think that’s possible with """ (because it always removes all common leading whitespace), but you can of course just write a normal string instead:

julia> " foo
         bar
         "
" foo\n  bar\n  "
1 Like