---
title: "appendItems(_:toSection:)"
framework: uikit
role: symbol
role_heading: Instance Method
path: "uikit/nsdiffabledatasourcesnapshot-swift.struct/appenditems(_:tosection:)"
---

# appendItems(_:toSection:)

Adds the items with the specified identifiers to the specified section of the snapshot.

## Declaration

```swift
mutating func appendItems(_ identifiers: [ItemIdentifierType], toSection sectionIdentifier: SectionIdentifierType? = nil)
```

## Parameters

- `identifiers`: An array of identifiers specifying the items to add to the snapshot.
- `sectionIdentifier`: The section to which to add the items. If no value is provided, the items are appended to the last section of the snapshot.

## See Also

### Creating a snapshot

- [init()](uikit/nsdiffabledatasourcesnapshot-swift.struct/init().md)
- [appendSections(_:)](uikit/nsdiffabledatasourcesnapshot-swift.struct/appendsections(_:).md)
