Skip to main content
Repeat children for each item in a data list.
{
  "type": "object",
  "properties": {
    "type": {
      "const": "ForEach",
      "default": "ForEach",
      "type": "string"
    },
    "cssClass": {
      "type": [
        "string",
        "null"
      ],
      "default": null,
      "description": "CSS/Tailwind classes for styling"
    },
    "children": {
      "type": "array",
      "items": {
        "$ref": "Component"
      }
    },
    "key": {
      "description": "Data field containing the list to iterate over",
      "type": "string"
    }
  },
  "required": [
    "type",
    "key"
  ]
}