Skip to content

Toon syntax

Gil Cleber Barboza edited this page Nov 12, 2026 · 1 revision

.toon syntax

Compact indented notation for the same payload as JSON. data[n] holds the records (dados[n] is a legacy alias).

meta:
  title: Sales Order
  mode: exact
layout:
  product{Product,str,left}
  total{Total,float,right,sum}
data[1]:
  - product: Pen
    total: 5.50
Pattern Meaning
key: value simple pair (int/float/bool auto-coerced)
key: + indented lines nested object
key[n]: + - ... items array
key[n]{a,b}: + v1,v2 lines array of objects
key{Label,format,align} compact layout field
key{Label,format,align,aggregate} compact layout field with sum|count|avg|min|max

A full example lives in examples/sales_order.toon.

Clone this wiki locally