This Week In React #204 : React at Meta, Next.js, StyleX, Mitosis, One, Hermes, Zeego, Nitro, TC39, Vite, Deno...
Sebastien Lorber
Posted on October 11, 2024
Hi everyone!
It's been another exciting week with great React cross-platform announcements at the Meta Connect event giving positive feedback on the usage of React Compiler, StyleX, React Strict DOM, and Hermes. I'm also excited for the React Compiler to add official support for React 18 and React 17 (experimental).
On the React Native side, we also had great releases and announcements, notably a new cross-platform framework from the Tamagui team, Zeego 2, native bottom tabs, and RN Storybook 8.
In the frontend world, Deno 2.0 just came out, and we also have a very exciting TC39 meeting happening right now.
Happy reading!
๐ก Subscribe to the official newsletter to receive an email every week!
๐ธ Sponsor
Securing Node.js Express APIs with Clerk and React
Learn how to use Clerk with Express to authenticate API requests.
Utilize the ClerkExpressWithAuth()
and ClerkExpressRequireAuth()
middleware to secure any endpoint and integrate authentication without the complexity of building it from scratch.
โ๏ธ React
At a recent event, Meta announced:
- New Instagram and Facebook mixed-reality apps for the Meta Quest headset. These apps use React Native and run on Static Hermes. The team was able to reuse existing Facebook web code and infrastructure thanks to technologies such as StyleX and React Strict DOM.
- A new Meta Horizon RN app that performs on par with their main native Facebook app. They mention the render-as-you-fetch pattern as the most impactful performance improvement they implemented.
- Meta Horizon Store for web/mobile/HorizonOS built using the bleeding-edge React Compiler, StyleX, React Strict DOM
- Meta Spatial Editor built on top of React Native Windows/macOS enables them to integrate natively their custom 3D rendering engine. The C++/Qt team was initially skeptical but ended up loving Fast Refresh.
Many great innovative projects are being dogfooded at Meta on real production apps, improving the framework and ecosystem for all of us along the way, for all platforms. With all this, we can confidently claim that Meta will continue to bet on React as an excellent cross-platform solution for the years to come.
See also the ๐ฅ commented video from Theo.
- ๐ธ Omlet โ A new tool for measuring React component usage across your repos. Try for free with unlimited scans and improve your code quality.
- ๐ React Router v7 Prerelease: The first prerelease (7.0.0-pre.0) is available on npm and you can already read the docs. The new version comes with a Vite plugin that enables React Router to be a full-stack framework (aka Remix). It also supports SSG, has a better config-based routing system, improves type-safety. RSC support will come later once React 19 and Vite Environment API are ready.
- ๐ React Compiler Docs - Usage with React v18 and v17 : A new official
react-compiler-runtime
package (experimental) has been published by the React team to support older versions of React. The babel config now accepts a newtarget: '17' | '18' | '19'
option. - ๐ Next.js Guide - Fixing breaking changes after v15.0.0-canary.171: For those living on the bleeding edge, the Next.js team explains how migrate the Dynamic APIs that now return promises.
- ๐๏ธ reactjsday - ๐ฎ๐น Verona - 25 October - Last call for tickets! Donโt forget โTWIRโ 10% discount code!
- ๐๏ธ React-Africa - ๐ฒ๐ฆ Casablanca - 29 November - Get a 10% discount with code โTWIRโ. And come listen from the best! Tejas Kumar et Jemima Abu will be here!
- ๐ Serverless servers and the challenge of new React architecture: Vercel recently launched a new โServerless Serversโ feature (wait, what? ๐ ) that enables a Serverless Function instance to behave more like a traditional Node.js server accepting concurrent requests while idling. React RSCs will be more cost-effective: you won't be charged for the time spent awaiting promises.
- ๐ Handling Form Validation Errors and Resets with useActionState: Teaches you how to handle React 19 resetting the fields of uncontrolled forms on submit.
- ๐ How Do Server Actions Work in NextJS?: Explains what happens under the hood when you call a Next.js Server Action, including simplified Next.js source code snippets.
- ๐ Using Mitosis to build a Design System: Mitigated feedback on this tool that permits creating cross-framework components from a shared JSX dialect.
- ๐ Increasing Vite's potential with the Environment API: A modern React RSC app needs to bundle the code in multiple ways, one for each environment (client, SSR, RSC). A Vite contributor explains how Vite 6 helps you do so efficiently, and presents other use cases.
- ๐ Code based routing in Next.js: Possible to achieve thanks to a catch-all route segment.
- ๐ Why Gumroad Didn't Choose htmx: Explain why they chose Next.js for their new product.
- ๐ React on the server is not PHP
- ๐ฆ StyleX 0.8 - LightningCSS post-processing, theming and linting improvements
- ๐ฆ JSX Email 2.0 - config file, plugins, email compat, CSS inlining, new components
- ๐ฆ Framer motion 11.11 -
animate()
can now animate any object such as Object3D from Three.js - ๐ฆ React-To-Print 3.0 - API modernization, React 19, smaller, Shadow DOM support, improved error handling
- ๐ฆ Assistant-UI - React Components for AI Chat
- ๐ฅ Lee Robinson - Self-Hosting Next.js: Including how to configure Next.js features like image optimization, caching, ISR, streaming, middleware โฆ
- ๐ฅ Sam Selikoff - How to share a React Component with the URL
- ๐ฅ Jack Herrington - 5 Hidden React Server Function TRAPS Beginners Fall Into
๐ธ Sponsor
Year after year, companies feast at the Open Source table, but few pay the maintainersโcreating burnout-related security incidents. Through the Pledge, forward-thinking companies are working together to change the status quo. Itโs time we paid our share. Will you join us?
๐ฑ React-Native
One - New cross-platform React framework
Nate, the creator of Tamagui, released a new universal framework that supports web and mobile. Itโs built on top of Vite instead of Metro, has universal typed file-based routing, Remix-like loaders, and various render modes (SSG/SSR/SPA). It also helps you build local-first apps with an opt-in integration with the granular Zero sync engine.
- ๐ธ Apryse React Native PDF Library - Easily add PDF viewing and editing to your cross-platform apps.
- ๐ Static Hermes for React Native โ Experimental Builds: Software Mansion is collaborating with the Hermes team on a fork to bring Static Hermes to RN apps, that you can try today, starting with iOS. Initial benchmarks show a 16% faster startup on a production app.
- ๐ React Native Docs PR - Discourage using controlled inputs in React Native because they are broken: Dan Abramov is unhappy about a core primitive of React Native not working as expected and suggests advising against using controlled inputs. Apparently, it used to work better but recent iOS features broke it (autocorrect and predictive text). The New Architecture allows synchronous native calls and might permit fixing it.
- ๐ React Native Testing Library Cookbook
- ๐ Journeying from React to React Native: Differences & Similarities
- ๐ฆ React Native Storybook 8: An important milestone for Storybook React Native which finally caught up with Storybook core and plans to keep it in sync thanks to shared infrastructure. This new major includes many new features, including a new mobile UI, widescreen layout, simpler Metro config, hot reloading, stable RNW support, and more.
- ๐ฆ React-Native-Bottom-Tabs - Bottom Tabs that use native platform primitives: An early version of the lib we mentioned last week, meant to be used with React-Navigation and replace its non-native JS-based implementation. Also works with Expo Router.
- ๐ฆ Zeego 2.0 - Cross-platform menus for React Native: Improves web support, drops the RNW dependency in favor of a thin RadixUI layer wrapper.
- ๐ฆ setup-ci - CLI to spin your CI/CD for react-native: New Software Mansion CLI project to help you quickly create RN GitHub Actions.
- ๐ฆ Nitro Modules 0.11 - Add Old Architecture support
- ๐ฆ React Native 0.76.0-rc.4
- ๐ฅ Simon Grimm - Build AI Powered Mobile Apps FASTER with Expo API Routes & Cursor
- ๐ฅ Reactiive - Animated Blur Cards with React Native (Skia)
- ๐๏ธ RNR 310 - Nitro with Marc Rousavy
- ๐๏ธ Rocket Ship 51 - React Native Brownfield Integration with Mariusz Stanisz
๐ Other
- ๐ TC39 - Agenda for the 104th meeting: The meeting is still in progress, but many proposals progressed to stage 4 and will be standardized in ES2025, weโll share the final list next week!
- ๐ Lucia Auth - Future plans: deprecate the library, transform to a learning resource
- ๐ Building a Single-Page App with htmx
- ๐ Do not use secrets in environment variables and here's how to do it better
- ๐ฆ Deno 2.0 - Backwards-compatible, forward-thinking
- ๐ฆ Brisa - Full-stack Framework with Server Components, Server Actions, JSX, Web Components, JSX: An interesting new framework inspired by React and Next.js and leveraging Declarative Shadow DOM for SSR.
- ๐ฆ Bun 1.1.30 - CSS Parsing & bundling, bun publish, CJS output
- ๐ฆ Better-Auth - The most comprehensive authentication library for TypeScript
๐คญ Fun
See ya! ๐
Posted on October 11, 2024
Join Our Newsletter. No Spam, Only the good stuff.
Sign up to receive the latest update from our blog.
Related
November 28, 2024
November 18, 2024