Home > @i2analyze/notebook-sdk > commands > IActionArea > surfaceGroup
commands.IActionArea.surfaceGroup() method
Surfaces a detached group, created with commands.ICommandApi.createGroup(), and its contents into the user interface.
Signature:
surfaceGroup(group: IGroupTemplate): void;
Introduced: version 1.10
Parameters
| Parameter | Type | Description |
|---|---|---|
| group | IGroupTemplate | The detached group template to surface. |
Returns:
void
Exceptions
Error if group was not a group template created by commands.ICommandApi.createGroup(), or if a command or group in the template was already surfaced in the area.
Remarks
Unlike commands.IActionArea.addGroup(), which builds a group in place, surfaceGroup adds a group template that you built once and can reuse. The group and its descendants are added at this area's location — use commands.IActionArea.before() or commands.IActionArea.after() to position it, just as you would when surfacing commands.
The template's group and command identifiers are used as they are, so you can surface the same template into different areas. Surfacing a template more than once into the same area throws, because the identifiers collide.