React Native — Unknown argument type ‘attribute’ in method -[RCTAppState getCurrentAppState:error:]. Extend RCTConvert to support this type.

Today, i updated my Xcode to version 11.0 to support iOS 13, suddenly my iOS App crashed.

My RN version is
“react”: “16.8.3”,
“react-native”: “0.59.5”

The solution is updating react-native into version 0.59.9 , or by modify this file [project_folder]/node_modules/react-native/React/Base/RCTModuleMethod.mm

search for about line 91, or looking for this
static BOOL RCTParseUnused(const char **input)

after this line
return RCTReadString(input, “__attribute__((unused))”) ||

add

RCTReadString(input, “__attribute__((__unused__))”) ||

then your project will working properly again.

References:
https://github.com/facebook/react-native/pull/25146/files

A long life student

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store