Loading video...

Video Failed to Load

Go Home

Build uncompromising high-performance, high-fidelity apps with React. What you see is not the Apple Messages app, nor is it meant to be 1:1. Rather it serves as an aspirational and real example of UI/UX that is possible. Every detail from the bubble animations to keyboard gestures to scroll view...

141,222 views • 1 month ago •via X (Twitter)

40 Comments

James Ide's profile picture
James Ide1 month ago

Running on Android. I don’t think this is what people expected when they asked for Android to get blue bubbles :P

Gregory Moskaliuk's profile picture
Gregory Moskaliuk1 month ago

Wow, this looks insane! If you ever need rich formatting inside those custom bubbles without tanking performance, we built react-native-enriched-markdown for this exact use case:

lauren's profile picture
lauren1 month ago

beautiful

James Ide's profile picture
James Ide1 month ago

Thank you!

Xuan Huang · 黄玄's profile picture
Xuan Huang · 黄玄1 month ago

@reactjs Beautiful UI Beautiful Writing Beautifully React Beautifully Native

Jamie Birch's profile picture
Jamie Birch1 month ago

The thing I am actually most astonished by is James’s laser-like accuracy when typing on the virtual keyboard during a recorded demo

Christoph Nakazawa's profile picture
Christoph Nakazawa1 month ago

Is this legal

James Ide's profile picture
James Ide1 month ago

Oh dear

Samuel Scheit's profile picture
Samuel Scheit1 month ago

Incredible work! Just a little nit-pick :) The send animation which transforms the input box into the message bubble needs a bit of polishing 1. bubble needs to stay visible at all times 2. bubble needs to stay on top of the input box 3. input box needs to slowly shrink in height

parbez's profile picture
parbez1 month ago

can you link to the repo? I want to steal some optimisations 😂

James Ide's profile picture
James Ide1 month ago

There’s a lot of code, what part do you want to know more about?

James Ide's profile picture
James Ide1 month ago

Animations: sending a chat bubble and revealing the timestamps on the side use Animated with the native driver. Reanimated would work well too. The Delivered/Read statuses and animating the bubbles’ positions use CSS Transitions. But without that API you could use (Re)Animated. Incoming chat messages and the typing indicator (not shown) use CSS Animations. The peek and pop effect is UIKit, including the way chat bubbles are lifted out of the scroll view and animate back to their original position when done. List: powered by VirtualView: There is some additional logic to make the chat bubbles cheap, like React.memo() and initializing the animated values only if a chat bubble is being sent and needs animation. The new scroll view I mentioned is for precise keyboard and safe area/inset handling and is not for speed. There is also some code to get the softly blurred headers on iOS 27. Native components: the chat bubbles are native because of the tails and animations. You could do this with SVG but it is likely faster to use CALayerPaths and there are potentially a lot of chat bubbles. The other native components are related to the keyboard and text composer because they are intrinsically coupled to UIKit’s delegate methods and must be frame-perfect. These pieces are infrastructure and I could see them maturing over time and being usable in most apps, instead of each developer rewriting their own implementation.

parbez's profile picture
parbez1 month ago

Thanks for the explanation

Spencer Taylor's profile picture
Spencer Taylor1 month ago

@expo Well said, and completely agree. “React and Native, not React vs. Native” Put that on a billboard.

Charles Vinette's profile picture
Charles Vinette1 month ago

Great post. An application is only as great as the level of polish and attention you give it.

Internet Labs's profile picture
Internet Labs1 month ago

Proving you can lock in 120 FPS by blending custom Swift layers with React Native completely buries the old bridge performance myth. Are you planning to package up that custom VirtualView scroll strategy as an open-source library?

James Ide's profile picture
James Ide1 month ago

VirtualView is open source and implements the cell rendering behavior: import {unstable_VirtualView as VirtualView} from 'react-native'; Docs: Stress test it with a few thousand views and work on making your cells as lightweight as you can. You’ll find it prioritizes rendering blanks (I believe this is also SwiftUI’s strategy) when the app can’t keep up. For real-world scrolling, it does a nice job of keeping scroll momentum and balancing how much off-screen content to pre-render.

Selva's profile picture
Selva1 month ago

Is the data static? Try fetching it from the backend using an infinite query, like you would in a real-world application. Or better yet, store it in expo-sqlite and read from there, with a background sync to keep it up to date. Will you still get 120 FPS?

James Ide's profile picture
James Ide1 month ago

The data is static which acts as a stress test for UI rendering since there is no network or data store to act as a bottleneck. The UI would have an easier time maintaining its frame rate when waiting for data with non-blocking fetches. I do think SQLite can perform very well, especially with the massive speed improvements in Expo Modules 2 and tuning how messages are fetched in batches. Would be good to measure it, I was focused just on the pure UI parts.

Selva's profile picture
Selva1 month ago

Well said! The UI work is beautiful.

Ahmad's profile picture
Ahmad1 month ago

does voiceover still read the bubbles in order with the timestamps moving separately??

Pavlo Nekrasov's profile picture
Pavlo Nekrasov1 month ago

Expo always delivers

Colin Hunt's profile picture
Colin Hunt1 month ago

Serious wow factor

Brian Hadu's profile picture
Brian Hadu1 month ago

aspirational examples are great, but they can set unrealistic expectations for developers

COURT's profile picture
COURT1 month ago

Can you please make an actual dummy build of this kit so we can play around with it and experience it before we signup? Just a mock iOS app in the AppStore that users can download and see the view in action. I don’t want to commit to anything without know if it will work for my project. It looks really great!

Serhii Y.'s profile picture
Serhii Y.1 month ago

"Uncompromised performance" is less impressive when it's only demonstrated on flagship hardware.

Nitesh ₿⚡️'s profile picture
Nitesh ₿⚡️1 month ago

Wish apple cared about the messages app as much as you did.

Tomas Martykan's profile picture
Tomas Martykan1 month ago

Very nice, GitHub link?

Azhar's profile picture
Azhar1 month ago

“Cofounder at expo” ah I see

Salem Shamakh 🇵🇸's profile picture
Salem Shamakh 🇵🇸1 month ago

Why you do not use legend list, also can you share code so we can learn from it

James Ide's profile picture
James Ide1 month ago

I wanted to try VirtualView. Legend List is great too I’m sure. It would be good to ship a lot of the infrastructural code into react-native core and Expo core upstream.

Hari · animata.design's profile picture
Hari · animata.design1 month ago

Great! Only that's bothering me is that sent message bubble animation

Gregor's profile picture
Gregor1 month ago

imo 'uncompromising' always loses to the reconciler the moment bubble animations hit real message volume

Stephen Rayner's profile picture
Stephen Rayner1 month ago

GitHub repo?

Forti's profile picture
Forti1 month ago

Make it open source 🥹

Juan Arreguin's profile picture
Juan Arreguin1 month ago

Those interaction details are my favorite part of building @PanolsApp too. Especially making the controls feel good while keeping the photos front and center.

Farzad Yousefzadeh's profile picture
Farzad Yousefzadeh1 month ago

@jamonholmgren good example demo for the recent debates you’ve been in? This can help widen the perspective of some blindly obsessed people you talk to 😊

Benji T's profile picture
Benji T1 month ago

React lookin' like Apple Messages and it ain't even tryin' to cosplay. This is the bar for mobile UI now.

Kgaugelo Kg's profile picture
Kgaugelo Kg1 month ago

What are the specific tradeoffs of the new scroll strategy during graceful degradation? Knowing these limitations would help determine when to swap it out for other options.

James Ide's profile picture
James Ide1 month ago

VirtualView skips rendering in favor of keeping scroll momentum. It will display blanks when it predicts the app will not meet its frame deadline, and the scroll view will keep moving with minimal stutter. In contrast, UIKit’s UITableView will freeze the scroll position until it has enough cells to display. This means there is always content on the screen but the scroll view is more likely to stutter when the app can’t keep up. Both approaches are valid and could share optimization strategies. For instance, in either case you could render a very cheap placeholder if you expect to miss your frame deadline. It would make VirtualView look better and UITableView perform better. And for the user, they’re often scrolling so fast in this scenario, it could be a good tradeoff to make.

Related Videos

AG-UI makes building agentic applications dramatically easier. Here's how it works. This is a model for a simple chatbot: User → LLM → Response But interactive agents that render UI, pause for approvals, and ask users for input need a much more complex model. When building these agents, a response from the LLM will include a series of state changes as the agent runs: • Agent started a task • Agent called a tool • Agent updated its state • Agent streams these tokens • Agent is waiting on a human • Agent is resuming the task The Agent-User Interaction Protocol (AG-UI) treats the LLM response as a stream of events rather than a text endpoint. In practice, here is what you get as an agent runs: 1. Lifecycle events so your UI knows where the agent is. 2. Text messages that stream tokens. 3. Tool calls so your UI can prefill a form with any required arguments. 4. State updates that keep your UI in sync with the agent. 5. Special events for human approvals, rich media, and custom needs. All of these events travel over standard transports (SSE, WebSockets, or plain HTTP) as JSON. As a result, you can build a frontend that stays in sync with the agent's progress without having to invent a custom process to make this happen. For example, building a human-in-the-loop workflow becomes an off-the-shelf component you can integrate rather than build from scratch. CopilotKit🪁 is the creator of AG-UI, and you can use it when building frontend applications pretty much anywhere: • React • Angular • Vue • React Native • Slack • Teams • Discord • WhatsApp • Telegram Here is the link for you to check it out: Thanks to the CopilotKit team for partnering with me on this post.

Santiago

17,438 views • 4 months ago