skip to Main Content

I am rebuilding my React Native 0.67.4 project by yarn add module one by one with Xcode 13/cocoapods 1.15. After a few modules added, run pod install and npx react-native run-ins to test with IOS 15 emulator. The following error occurs after a few module added and pod install successfully. I sense that the error is pod related but don’t know how to fix it. Here is the error

/Users/macair/Documents/code/js/xyz_app6/node_modules/react-native/React/CoreModules/RCTActionSheetManager.mm:98:35: error: no member named 'cancelButtonTintColor' in 'JS::NativeActionSheetManager::SpecShowActionSheetWithOptionsOptions'
      [RCTConvert UIColor:options.cancelButtonTintColor() ? @(*options.cancelButtonTintColor()) : nil];
                          ~~~~~~~ ^
/Users/macair/Documents/code/js/xyz_app6/node_modules/react-native/React/CoreModules/RCTActionSheetManager.mm:98:72: error: no member named 'cancelButtonTintColor' in 'JS::NativeActionSheetManager::SpecShowActionSheetWithOptionsOptions'
      [RCTConvert UIColor:options.cancelButtonTintColor() ? @(*options.cancelButtonTintColor()) : nil];
                                                               ~~~~~~~ ^
2 errors generated.

......

** BUILD FAILED **


The following build commands failed:
    CompileC /Users/macair/Library/Developer/Xcode/DerivedData/xyz_app6-drkombcrczieyyfirepznaljzqwr/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/React-CoreModules.build/Objects-normal/x86_64/RCTActionSheetManager.o /Users/macair/Documents/code/js/xyz_app6/node_modules/react-native/React/CoreModules/RCTActionSheetManager.mm normal x86_64 objective-c++ com.apple.compilers.llvm.clang.1_0.compiler (in target 'React-CoreModules' from project 'Pods')
(1 failure)

2

Answers


  1. Perform the below steps:

    1. delete node_modules folder
    2. npm install or yarn install
    3. delete pods folder and Podfile.lock file
    4. cd ios && pod install
    5. Run the project npx react-native run-ios

    Hope it works!

    Login or Signup to reply.
  2. I’ve tried cleaning everything but it didn’t work for me. In the end the issue was related to the iOS deployment target of the React-Codegen pod. Changing it to my project’s minimum iOS version worked for me. See this comment; https://github.com/facebook/react-native/issues/34126#issuecomment-1492157907

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search