View profile

This Week In React #105: useEvent, Next.js Layouts, Remix, Storybook, Reanimated 3, Expo 45, Tamagui, TypeScript, Markdoc...

This Week In React #105: useEvent, Next.js Layouts, Remix, Storybook, Reanimated 3, Expo 45, Tamagui, TypeScript, Markdoc...
By Sébastien Lorber • Issue #105 • View online
Hi everyone!
🏖 Back from holidays 😎 Menorca is a really beautiful island, in particular if you like hiking close to beautiful beaches.
Way too much content to cover in 3 weeks 😅 I’m just putting the important links for the Other section, but there are some very interesting things to read there!
🙏 Support the newsletter:

Dan Abramov’s RFC suggests to add a new useEvent(fn) hook in React core, without any dependency array. The unstable function/closure passed as a parameter is then stabilized (it keeps the same identity over time). This helps avoid the stale closure problem (when ESLint rules are not respected) while simplifying optimization via React.memo(), and avoiding useEffects from re-executing. Changes planned to ESLint rules: the stabilized function does not need to be passed into other dependency arrays, and an “onEvent” / “handleEvent” convention could be adopted.
I gave my positive feedback in the pull-request (lots of comments there, especially on the naming of that hook). For me, it’s really a missing piece in the initial hooks design, and many apps already use a workaround based on useLayoutEffect.
useEvent, the missing React hook is a great 3 minutes video to understand the big picture.
Next.js will modernize its routing infrastructure. This will help leverage React 18 features, and other upcoming features.
They plan for incremental adoption: the ./pages folder continues to work as before, and you can gradually move things to a new ./app folder, which also activates Server Components 🤯.
There will be support for nested routes/layouts based on a layout.js naming convention. Requests will be executed in parallel (without waterfall). This article is only the 1st part of a huge RFC: the 2nd part is coming.
💸 Sponsors
Axiom enables you to monitor the health and performance of your Vercel deployments by ingesting all your request, function, and web vitals data.
Use Axiom’s pre-built dashboard for an overview across all your Vercel logs and vitals, drill down to specific projects and deployments, and get insight on how functions are performing with a single click. 
Retool is a new approach to building internal apps: we’ve unified the ease of visual programming with the power and flexibility of real code. Drag and drop a form together, and have it POST back to your API in minutes. Deploy instantly with access controls and audit logs.
New version in RC. Supports the new Fabric architecture, but also the old one to help gradual adoption. Reanimated v2 code continues to work on v3, but the old Reanimated v1 API is removed. Bonus: demo Reanimated 3 + RNGH + Screens
Adam announces the launch of the React Native Developer Tools community project. This is a repo (rnx-kit) with many useful tools for a React-Native project related to Metro, TypeScript, Jest… Microsoft already uses it on various products like Office, Xbox, and Teams.
  • Start React Native: learn everything about gestures and animations with William Candillon
  • Adventures in Nodeland: Matteo writes about his journey as a Node.js TSC member and maintainer of 500+ modules on npm, including Fastify and Pino!
  • TypeScript Weekly: the best TypeScript links every week, right in your inbox
  • Tailwind Weekly: all things Tailwind CSS, new issue every Saturday
  • G2i: pre-vetted remote React & React-Native developers you can trust on contract or full-time basis
  • Infinite Red: US React-Native experts making your idea a reality
  • Software Mansion: the co-creators of React Native and the technological core of many tech companies
Did you enjoy this issue?
Sébastien Lorber

📨 For React and React-Native developers ⚛️ I filter out the noise 🔊 You save time ⏱️ Stop losing your time scrolling on Twitter! 🐦

⚠️ The newsletter has moved!
➡️ Go to

In order to unsubscribe, click here.
If you were forwarded this newsletter and you like it, you can subscribe here.
Powered by Revue