psych icon indicating copy to clipboard operation
psych copied to clipboard

Feature: configure block scalar type

Open wscourge opened this issue 2 years ago • 0 comments

I'd like to be able to do the following:

{
  long_string_content: "This is a very long string that I want to display in a literal block in my YAML output"
}.to_yaml(fold: "|")

With acceptable :fold basic values: |, >, and other combinations such as |- or >+.

Inspired by this SO answer

wscourge avatar Mar 20 '23 14:03 wscourge