We’ve been hard at work to create a first-look at data fetching, server rendering, and streaming in universal Expo Router apps.
This talk has been presented at React Summit 2024, check out the latest edition of this React Conference.



Crashes, slowdowns, regressions in prod. Seer by Sentry unifies traces, replays, errors, profiles to find root causes fast.
We’ve been hard at work to create a first-look at data fetching, server rendering, and streaming in universal Expo Router apps.
This talk has been presented at React Summit 2024, check out the latest edition of this React Conference.
React Native is a framework for building native applications using JavaScript and React. It allows developers to create apps that run on both iOS and Android platforms using the same codebase.
Evan Bacon is an engineer and the creator of ExpoRouter, a file-based routing mechanism for building React apps that run on both web and native platforms from the same codebase.
ExpoRouter is a file-based routing mechanism for building React apps that run on both web and native platforms from the same codebase. It uses familiar web APIs like link and href and supports nested routing for organizing routes.
ExpoRouter simplifies the integration of AI by enabling server-driven UI and streaming server-rendered content. This makes it easier to build high-powered AI native apps that can interact with server-side logic in real-time.
Server-driven UI enables dynamic rendering based on various criteria such as user type, location, and more. It allows for A/B testing and high variation in UI, leading to better performance and user experience.
The source code for ExpoRouter is being actively developed and merged into the Expo repo. Developers can follow the progress on GitHub and will be able to access it once it is officially released.
ExpoRouter complies with app store policies by not sending any native code dynamically. It adheres to guidelines that prevent changing the approved content and behavior of an app, ensuring that all features are pre-approved.
ExpoRouter supports iOS, Android, web, and other platforms through its universal file-based routing system. It provides a seamless experience across different devices and operating systems.
ExpoRouter improves developer experience by simplifying the creation of server-driven UIs, reducing the need for client-side data fetching, and enabling rapid development with a unified codebase for web and native apps.
React Server Components are a cutting-edge approach to server rendering, allowing for the seamless integration of server and client code. They enable dynamic, server-driven UIs and reduce the need for client-side data fetching.
React Native has grown to become the most impactful way to build client-side applications. I'm Evan Bacon, an engineer and the creator of exporouter. It's the first file-based routing mechanism for building React apps that run on both web and native platforms from the same code base. It uses familiar web APIs like link and href to move between routes, and it's also a nested routing system. Expo provides universal solutions to most aspects of app development. Data fetching and server rendering bring interesting opportunities.
When React Native was first announced nearly 10 years ago, it had a very simple premise, which was web the good parts. From this basic concept, React Native has grown to become the most impactful way to build client-side applications. If you fast-forward to now, React Native powers hundreds of the most-used apps in the app store trending list every single day. Really no signs of slowing down. So where do we go from here?
I'm Evan Bacon, an engineer and the creator of exporouter. It's the first file-based routing mechanism for building React apps that run on both web and native platforms from the same code base. It feels like magic. By simply creating files in the app directory, exporouter instantly creates robust navigation for both your native app and your website. It uses familiar web APIs like link and href to move between routes, and it's also a nested routing system, enabling you to organize routes into folders to establish shared UI like tab bars, headers, drawers, so on and so forth. And it's also a... It also has day-one support for the new React compiler, thanks to our collaboration with the meta team. This means you no longer need to write use memo or use callback in your apps, leading to a much better experience for both users and developers. We'll be installing compiler by default in the next version of Expo CLI, so you can flip it on and off. It's actually pretty sweet, because you can turn it off without having to restart the dev server. Really slick. There are many aspects to app development, and Expo provides universal solutions to most of them. But all of these solutions are primarily targeted at building client-side applications. And there's only so much that you can do with the client on its own. Things get really interesting when you bring in data fetching and server rendering.
Most native apps operate like single-page websites, resulting in slower performance and limited networking. Popular apps utilize server-driven UI for A-B testing and dynamic rendering. However, indie developers often face challenges due to the lack of accessible frameworks. ExpoRouter aims to address this by introducing React server components, enabling powerful server-driven UI for all platforms. The progress in implementing React server components is exciting, showcasing the potential of modern rendering techniques. With ExpoRouter, building high-powered AI native apps becomes easier, utilizing streaming and server rendering capabilities.
From a data perspective, most native apps operate essentially like single-page websites. Which is old now data. This means slower performance and substantially less networking. Popular native apps such as Lyft and Netflix, Reddit, and many others use some form of server-driven UI in their applications. But it's very complicated to configure, and as a result, it's out of reach for most app developers.
They do this so they can A-B test functionality and render UI with a high degree of variation based on all sorts of criteria, such as user type, location, the currency you use, the temperature in your region, lots of different things. The approaches vary in many small ways, but they do share some common architecture, such as using JSON as a static UI representation. Think of this JSON as HTML, but for custom native runtimes. And we can see a pattern here from the amount of apps that use all these very similar systems. And that is that server-driven UI is an important system for building apps, but it's just not very accessible to indie developers. All these groups have these frameworks. They are not open source.
So it got me to thinking. What if we could make server-driven UI available to everyone? But also the most powerful version of it ever imagined. And that is the goal of ExpoRouter. Now, to do this, we're bringing React server components, the most cutting-edge approach to server rendering to all platforms, iOS, Android Web, and anything else, through ExpoRouter. This is a huge undertaking. This will require refinement in many different libraries across the universal ecosystem. Our official implementation of React server components for universal apps is currently in early development. But it's worth sharing, because the progress is really exciting. And frankly, it's pretty inspiring to see what apps are capable of when they use modern rendering techniques from the web.
Now, there's a lot to RSE, such as server actions, concurrent routing, flights, et cetera. But I figured it would be easier to just show you guys a demo of what's possible. So I've been really interested in AI, as has everyone. But it's historically been very hard to build high-powered AI native apps. And this is because streaming and server rendering are both critical aspects of working with an LLM. But with React server components and ExpoRouter, it's actually really, really easy to work with AI. So here I have a chat GPT-like app which pings OpenAI with a React server action and streams in native text from the server. So think of this as a chat GPT-style app, right? Everything that returns back from the server is server rendered, though. Or at least partially server rendered, because we also have client components.
We constantly think of articles and videos that might spark Git people interest / skill us up or help building a stellar career
Comments