Files
Serj AgopianandGitHub ec926570b3 examples: Upgrade with-react-native-web example to use latest versions (#12085)
## Description

This PR upgrades the with-react-native-web example from Expo SDK 52 to
SDK 55, bringing it up to date with the latest stable releases.
#### Major Version Updates:
  - Expo: 52.0.49 → 55.0.4
  - React: 18.3.1 → 19.2.0
  - React DOM: 18.3.1 → 19.2.0
  - React Native: 0.76.9 → 0.83.2
  - React Native Web: 0.19.10/0.19.13 → 0.21.0
  - TypeScript: 5.5.4/5.8.3 → 5.9.2

#### Configuration Updates:
- Removed newArchEnabled from app.json (now enabled by default in SDK
55)
  - Removed implicit @babel/core dependency (managed by Expo)
  - Removed babel.config.js (only contained default preset)
- Removed disableHierarchicalLookup from Metro config (no longer
recommended)
- Added Turbopack configuration to Next.js config for react-native-web
aliasing

#### Build Fixes:
  - Added @types/minimatch to fix TypeScript declaration generation
  - Configured tsup with skipLibCheck to prevent type resolution issues
  - Updated TypeScript configs to prevent implicit type loading

#### Verification
- Ran npx-expo doctor
- Ran yarn install
- Ran yarn turbo build
- Ran yarn dev and launched the iOS and Web applications
2026-03-01 20:14:54 -07:00

35 lines
696 B
JavaScript

module.exports = {
reactStrictMode: true,
turbopack: {
resolveAlias: {
"react-native": "react-native-web",
},
resolveExtensions: [
".web.js",
".web.jsx",
".web.ts",
".web.tsx",
".js",
".jsx",
".ts",
".tsx",
".json",
],
},
webpack: (config) => {
config.resolve.alias = {
...(config.resolve.alias || {}),
// Transform all direct `react-native` imports to `react-native-web`
"react-native$": "react-native-web",
};
config.resolve.extensions = [
".web.js",
".web.jsx",
".web.ts",
".web.tsx",
...config.resolve.extensions,
];
return config;
},
};