Skip to content

feat: Upgrade example project to React Native 0.80.2 - #3917

Merged
mfazekas merged 6 commits into
mainfrom
upgrade-rn-080
Aug 7, 2025
Merged

mfazekas merged 6 commits into
mainfrom
upgrade-rn-080

Conversation

@mfazekas

@mfazekas mfazekas commented Aug 6, 2025

Copy link
Copy Markdown
Contributor

Summary

  • Upgrades the example project from React Native 0.79.1 to 0.80.2
  • Fixes Kotlin 2.1.20 nullability issues with proper error logging
  • Updates all related dependencies and configurations

Changes

React Native & Dependencies

  • Updated React Native to 0.80.2
  • Updated React to 19.1.0
  • Updated Metro and related bundler dependencies
  • Updated React Native CLI to 19.0.0
  • Updated react-native-screens to 4.13.1 for ChoreographerCompat compatibility

Android Changes

  • Updated Kotlin to 2.1.20 with stricter null safety
  • Updated Gradle wrapper to 8.14.1
  • Fixed MainApplication.kt to use loadReactNative() instead of deprecated SoLoader.init()
  • Fixed 20+ Kotlin files with proper null checking and error logging pattern
  • Updated AGP to 8.10.2

iOS Changes

  • Enabled bridgeless mode for New Architecture
  • Updated Podfile configuration for RN 0.80
  • Fixed iOS build configuration

Kotlin Nullability Fixes

Applied consistent null checking pattern with error logging across all affected files:

val value = dynamic.asArray()
if (value == null) {
    Logger.e("ClassName", "descriptive error message")
    return
}
// Use value safely

Test Plan

  • Android build succeeds
  • iOS pod install succeeds
  • TypeScript type checking passes
  • Lint passes

Related Issue

Fixes #3915

🤖 Generated with Claude Code

Co-Authored-By: Claude noreply@anthropic.com

mfazekas and others added 3 commits August 6, 2025 22:41
## Changes

### Dependencies
- Upgrade React Native from 0.79.1 to 0.80.2
- Upgrade React from 19.0.0 to 19.1.0 (required for RN 0.80)
- Upgrade React Native CLI to 19.0.0
- Upgrade all @react-native/* packages to 0.80.2
- Upgrade react-native-screens to 4.13.1 for RN 0.80 compatibility

### Android
- Update Kotlin version to 2.1.20 (RN 0.80 recommended)
- Update Gradle to 8.14.1
- Fix nullability issues in 20+ Kotlin files for stricter type checking
- Update MainApplication.kt to use loadReactNative() instead of SoLoader
- Add proper null checks with error logging throughout codebase

### iOS
- Enable bridgeless mode in AppDelegate.mm
- Update iOS pods for RN 0.80 compatibility

### Configuration
- Update metro.config.js (blacklistRE → blockList)
- Enable New Architecture (newArchEnabled=true)
- Enable Hermes (hermesEnabled=true)

Fixes #3915

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
@mfazekas
mfazekas merged commit e31ee74 into main Aug 7, 2025
11 checks passed
@mfazekas
mfazekas deleted the upgrade-rn-080 branch August 7, 2025 05:28
efstathiosntonas pushed a commit to efstathiosntonas/maps that referenced this pull request Aug 8, 2025
* feat: Upgrade example project to React Native 0.80.2

## Changes

### Dependencies
- Upgrade React Native from 0.79.1 to 0.80.2
- Upgrade React from 19.0.0 to 19.1.0 (required for RN 0.80)
- Upgrade React Native CLI to 19.0.0
- Upgrade all @react-native/* packages to 0.80.2
- Upgrade react-native-screens to 4.13.1 for RN 0.80 compatibility

### Android
- Update Kotlin version to 2.1.20 (RN 0.80 recommended)
- Update Gradle to 8.14.1
- Fix nullability issues in 20+ Kotlin files for stricter type checking
- Update MainApplication.kt to use loadReactNative() instead of SoLoader
- Add proper null checks with error logging throughout codebase

### iOS
- Enable bridgeless mode in AppDelegate.mm
- Update iOS pods for RN 0.80 compatibility

### Configuration
- Update metro.config.js (blacklistRE → blockList)
- Enable New Architecture (newArchEnabled=true)
- Enable Hermes (hermesEnabled=true)

Fixes rnmapbox#3915

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>

* pnpm -> yarn

* run generate

* fix: Use correct gradle-wrapper.jar from RN 0.80.2 template

* fix(android): Handle nullable sourceLayerID in RNMBXModelLayer for Kotlin 2.1.20 compatibility

* fix: Revert pnpm references back to yarn

---------

Co-authored-by: Claude <noreply@anthropic.com>
@ahmadkhalaf1

Copy link
Copy Markdown

@mfazekas Thank you for your PR
any plan to release this to unblock using mapbox with react native 80.2 ?
thanks

@mfazekas

Copy link
Copy Markdown
Contributor Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Unable to install with react native 0.80.x (Android)

2 participants