not found (RN 0.63)

Bug report

Summary

I’m creating a new project and trying to install react-native-maps and GoogleMaps for iOS.

Environment info

react-native info output:

System:
    OS: macOS 10.15.7
    CPU: (4) x64 Intel(R) Core(TM) i5-4278U CPU @ 2.60GHz
    Memory: 722.99 MB / 16.00 GB
    Shell: 5.7.1 - /bin/zsh
  Binaries:
    Node: 14.9.0 - /usr/local/bin/node
    Yarn: Not Found
    npm: 6.14.7 - /usr/local/bin/npm
    Watchman: 4.9.0 - /usr/local/bin/watchman
  Managers:
    CocoaPods: 1.10.0 - /usr/local/bin/pod
  SDKs:
    iOS SDK:
      Platforms: iOS 14.3, DriverKit 20.2, macOS 11.1, tvOS 14.3, watchOS 7.2
    Android SDK: Not Found
  IDEs:
    Android Studio: 4.0 AI-193.6911.18.40.6626763
    Xcode: 12.3/12C33 - /usr/bin/xcodebuild
  Languages:
    Java: 11.0.8 - /usr/bin/javac
    Python: 2.7.16 - /usr/bin/python
  npmPackages:
    @react-native-community/cli: Not Found
    react: 16.13.1 => 16.13.1 
    react-native: 0.63.3 => 0.63.3 
    react-native-macos: Not Found
  npmGlobalPackages:
    *react-native*: Not Found
      react-native: 0.63.3
      react: 16.13.1
      react-native-maps: 0.27.1

Steps to reproduce

  1. Create new project
  2. Add use_frameworks! in the Podfile
  3. Add in the Podfile:
# react-native-maps dependencies
  rn_maps_path = '../node_modules/react-native-maps'
  pod 'react-native-google-maps', path: rn_maps_path
  pod 'GoogleMaps'
  pod 'Google-Maps-iOS-Utils', '~> 3.4.2'
  1. Remove react-native-maps dependencies (in node_modules/react-native-maps/react-native-google-maps.podspec) so you can have the latest version of Google-Maps-iOS-Utils (which supports use_frameworks!)
  2. pod install
  3. Build in xcode

Describe what you expected to happen:

Build successful

Describe what actually happens:

Capture d’écran 2020-12-17 à 11 31 55

Reproducible sample code

1 possible answer(s) on “ not found (RN 0.63)

  1. I fixed it by removing everything and starting the install again.

    • rm -rf node_modules
    • Add only in the Podfile:
    pod 'GoogleMaps'
    pod 'Google-Maps-iOS-Utils'
    
    • pod install
    • In XCode, “add files to {project_name} …” -> node_modules/react-native-maps/lib/ios/AirGoogleMaps and node_modules/react-native-maps/lib/ios/AirMaps
    • Change import in {project_name}/AirGoogleMaps/AIRGoogleMapHeatmap.h to #import "GMUHeatmapTileLayer.h"
    • And don’t forget to add the API Key in your AppDelegate