Description
ChatLayout is an open-source Swift library for building chat interfaces on iOS, offered as an alternative to MessageKit. It is a custom UICollectionViewLayout, so you keep full control over presentation and can use every tool UICollectionView offers. It supports cells and supplementary views with dynamic sizes, animated insertion, deletion, reloading and moving of items, and keeps the last visible item anchored at the top or bottom during updates. It includes tools for scrolling precisely to a given item, generic container views that make custom message cells easier, and pinned cells that behave like sticky headers or footers. Because it is just a layout, you do not subclass a special view controller or collection view, the collection view is not flipped upside down, and you do not need to calculate all cell sizes up front. Recent versions add an agent mode.…
Highlights
- Custom UICollectionViewLayout for chat UIs
- Dynamic cell and supplementary view sizes
- Animated insert, delete, reload and move
- Keeps position anchored during updates
- Precise scrolling and sticky pinned cells
- Generic container views for custom items
Ratings & Reviews
No ratings yet
Be the first to rate ChatLayout.
People also visit
RSKGrowingTextView
A light-weight UITextView subclass that automatically grows and shrinks
ChatLayout FAQ
What is ChatLayout?
A custom UICollectionViewLayout for building chat screens on iOS, as an alternative to MessageKit.
Do I need to subclass a special view controller?
No. You create your own UIViewController and UICollectionView and use them normally.
Does it flip the collection view upside down?
No. It does not rely on a modified flow layout or rotation, so cells behave like regular cells.
Do I have to calculate cell sizes in advance?
No, it supports dynamic cell sizes without precomputing all of them before rendering.
What are the best ChatLayout alternatives?
Popular alternatives to ChatLayout include MessageKit, React Native Gifted Chat and Chatview. See all ChatLayout alternatives



