rougail-output-doc/tests/docs/examples/60_1family_dynamic_jinja.md

506 B

Table of Contents

dictionaries/rougail/00-base.yml

---
version: '1.1'
var:  # a suffix variable
  - val1
  - val2
dyn{{ identifier }}:
  description: A dynamic family
  dynamic:
    jinja: |
      {% for val in _.var %}
      {{ loop.index }}
      {% endfor %}      
    description: index of suffix value
  var: val  # a dynamic variable

Example with all variables modifiable

---
rougail:
  var:
    - val1
    - val2
  dyn1:
    var: val
  dyn2:
    var: val