# `GSShapeGroup enumerateMembersWithBlock:`

*Instance Method*

Calls the block with every member of the group, including nested shapes.

## Declaration

```swift
func enumerateMembers(_ code: @escaping @Sendable (GSShape) -> Void)
```

```swift
func enumerateMembers() async -> GSShape
```

```objc
- (void) enumerateMembersWithBlock:(void (^)(GSShape *member)) code;
```

```python
enumerateMembersWithBlock_(member: GSShape, code)
```

## Discussion

The order is the same as the order on `layer.shapes`, i.e., the compositing order (bottom to top).

This enumeration also works when the shape group does not belong to a layer.

