Monorepo: React Web & React Native
summary
Argues that sharing code between React Web and React Native is possible but brittle for nontrivial apps, demonstrates a Lerna monorepo with packages: web, mobile, and a shared package exporting a date-format function that runs on both, uses Yarn and create-react-app for web, Metro bundler and Expo for mobile, and shows watch-and-copy (Watchman) strategies failing under heavy change. Warns about platform APIs (localStorage vs AsyncStorage), styling and list-data differences; recommends this for large projects only and labels react-native for web integration fragile.
AI-written summary · about
chapters (8)
- 0:00Intro
- 2:54React Native for Web
- 8:49Extract shared to a separate package
- 11:53Last update 2 years ago Unstable
- 14:51Lerna Tool for managing JavaScript projects with multiple packages
- 21:30Core code should be platform agnostic
- 23:00Web and Mobile application should behave similar
- 26:37Question
related talks
34mMonorepo: React Web & React Native
28mCross-Platform React
46mReact Native for Web Panel Discussion
59mOne Codebase to Rule Them All - Using React Native Everywhere
29mUniversal React
08mLightning talk from Lenka Vondrackova
16mBuilding Cross-Platform Apps with React Native + Next.js
07mSharing a Codebase with React & React Native
