From 5ab7bd96a3b11fe53cedf23e6e391c09f21f3a42 Mon Sep 17 00:00:00 2001 From: Scott Kyle Date: Fri, 13 Nov 2015 11:21:55 -0800 Subject: [PATCH] Added comment about React Native version support --- ReactNative/RealmReact.mm | 1 + 1 file changed, 1 insertion(+) diff --git a/ReactNative/RealmReact.mm b/ReactNative/RealmReact.mm index 66135a01..1550ab36 100644 --- a/ReactNative/RealmReact.mm +++ b/ReactNative/RealmReact.mm @@ -31,6 +31,7 @@ JSGlobalContextRef RealmReactGetJSGlobalContextForExecutor(id executor, bool cre NSMethodSignature *signature = [RCTJavaScriptContext instanceMethodSignatureForSelector:@selector(initWithJSContext:)]; assert(signature); + // React Native 0.14+ expects a JSContext here, but we also support 0.13.x, which takes a JSGlobalContextRef. if (!strcmp([signature getArgumentTypeAtIndex:2], "@")) { JSContext *context = [[JSContext alloc] init]; rctJSContext = [[RCTJavaScriptContext alloc] initWithJSContext:(void *)context];