프론트엔드 개발자의 개발 놀이터

RN 다양한 에러 대응 본문

React Native

RN 다양한 에러 대응

프론트포텐 2024. 2. 2. 15:15
반응형

1. 'value' is unavailable: introduced in iOS 12.0

node_modules/react-native/scripts/cocoapods/codegen_utils.rb 경로의 87 라인

'ios' => '11.0',   'ios' => '12.0’, 변경 후

ios 폴더 경로에서 pod install

 

2. [!] CocoaPods could not find compatible versions for pod "react-native-safe-area-context" ~~~

Podfile platform :ios, '11.0’ ’12.0’ 변경 pod install

 

3. [!] Unable to find a specification for `React-hermes` depended upon by `RNReanimated`~~~

Podfile 에

ENV['USE_HERMES'] = '0'

코드 붙여넣고 pod install

 

4. ~~~/ReactCommon/yoga/yoga/Yoga.cpp:2232:9: use of bitwise '|' with boolean operands [-Werror,-Wbitwise-instead-of-logical]

node->getLayout().hadOverflow() | 를

node->getLayout().hadOverflow() || 변경 후 저장

 

5. error Failed to build iOS project. We ran "xcodebuild" command but it exited with error code 65.

use_flipper!() 를

use_flipper!({ 'Flipper' => '0.159.0' })  변경

 

6. 안드로이드에서 toLocaleString() 동작하지 않을

android/app/build.gradle 파일의

def jscFlavor = 'org.webkit:android-jsc:+' 를

def jscFlavor = 'org.webkit:android-jsc-intl:+' 로 변경 후 클린 빌드 후 재실행

 

7. Unrecognized font family ~~~~~

폰트의 postScriptName 사용하지 않아서 생기는 오류

 

 

FontDrop!

Simple and easy way to view the content of font files.

fontdrop.info

해당 사이트에서 ttf 파일을 올리고 Data 탭을 클릭해 나오는 postScriptName 실제 font-family 사용하면 된다.

8. Error (Xcode): Cycle inside Runner; building could produce unreliable results

TARGETS ->[Projects] -> Build Phases에서 실행 순서 정렬하고 재실행하기.

 

9. SendProcessControlEvent:toPid: encountered an error: Error Domain=~~ Code=8

Clean Builder Folder 후 재실행.


10. Called object type 'facebook::flipper::SocketCertificateProvider'(aka 'int') is not a function~~~

Pods > Flipper > FlipperTransportTypes.h 파일에 아래 코드 추가.

 

#include <functional>