# tui/add-to-group
Add a new empty panel as a child inside a group. The new panel appears
alongside the group's existing children.
## Syntax
[tui/add-to-group group-id] [tui/add-to-group group-id :horizontal] [tui/add-to-group group-id :vertical]
## Parameters
| Parameter | Description |
|-----------|-------------|
| `group-id` | Numeric ID of the target group (from `tui/groups`) |
| `:horizontal` (default) | Stack the new panel below the group |
| `:vertical` | Place the new panel to the right of the group |
## Returns
The numeric ID of the new panel, suitable for passing to `tui/launch`.
## Example
# Get all groups, add a sibling to the first one, launch editor set groups [tui/groups] if ([len $groups] > 0) { set grp [nth $groups 0] set new-id [tui/add-to-group $grp~id :horizontal] [tui/launch $new-id "editor" "apps/editor/editor.dft"] }
## See Also
`tui/groups`, `tui/split`, `tui/launch`