---
title: "HBS_CHILDREN"
manual: "Handlebars"
version: "main"
permalink: "https://docs.typo3.org/permalink/cpsit/typo3-handlebars-forms:co-hbs-children@main"
source: "Usage/ContentObjects/Children.rst"
rendered: "2026-09-29T09:18:02+00:00"
---

# HBS_CHILDREN {#co-hbs-children}

Returns the children of the current view model as a list. The view model must implement
`CompositeViewModel` (e.g. `ViewModelCollection`). Returns `null` when the
view model has no children.

Each child is processed using the sub-configuration of `HBS_CHILDREN`.

**Frontend register**

While iterating, `HBS_CHILDREN` writes two values to the frontend register
that TypoScript conditions can read via [register](https://docs.typo3.org/m/typo3/reference-typoscript/main/en-us/Functions/Data.html#data-type-gettext-register):

-   `HBS_CHILDREN_COUNT` – number of children
-   `HBS_CHILDREN_CURRENT` – index of the child being processed (unset after the loop)

> [!NOTE]
> Since TYPO3 v14 the register is part of the frontend register stack on the global
> request object (`frontend.register.stack` request attribute) rather than the
> legacy `$GLOBALS['TSFE']->register` array. The extension handles both automatically.

**Example**

```typoscript
options = HBS_CHILDREN
options {
    label = HBS_LABEL

    checked = HBS_TAG
    checked.attribute = checked
}
```
