CometChatNotificationFeed displays a scrollable notification feed where each item is rendered as a native card using the CometChat Cards library. It handles fetching, pagination, category filtering, real-time updates, and read/delivered/engagement reporting automatically. Present it in a UINavigationController, push it onto an existing navigation stack, or embed it in a tab bar.
Each notification gets its own section header with the category label on the left and a relative timestamp on the right:
- Swift
Quick Start
- Swift
CometChatUIKit.init() and a user logged in.
Filtering Feed Items
Control what loads using custom request builders:- Swift
Filter Options
Pass the builder object, not the result of
.build(). The component calls .build() internally.
Actions and Events
onItemClick
Fires when a feed item card is tapped.- Swift
onActionClick
Fires when an interactive element (button, link) inside a card is tapped.- Swift
onError
Fires when an internal error occurs (network failure, SDK exception).- Swift
Automatic Behaviors
The component handles these automatically — no manual setup needed:Functionality
- Swift
Common Patterns
Show only unread items
- Swift
Hide filter chips
- Swift
Custom categories request
- Swift
Embed in a Tab Bar
- Swift
Handle action + report engagement
- Swift