Thursday, December 6, 2018

What is Indentation and Separation in YAML?

Indentation of YAML

YAML does not include any mandatory spaces. Further, there is no need to be consistent. The valid YAML indentation is shown below −
a:
   b:
      - c
      -  d
      - e
f:
      "ghi"
  • You should remember the following rules while working with indentation in YAML:Flow blocks must be intended with at least some spaces with surrounding current block level.
  • Flow content of YAML spans multiple lines. The beginning of flow content begins with { or [.
  • Block list items include same indentation as the surrounding block level because - is considered as a part of indentation.
https://www.tutorialspoint.com/index.htm

No comments:

Post a Comment