[ReactNative] Allow bridge modules to run on the JavaScript thread

This commit is contained in:
Tadeu Zagallo
2015-04-25 19:18:39 -07:00
parent 8a3b0fa9e8
commit dd6bce78e1
4 changed files with 41 additions and 15 deletions

View File

@@ -17,6 +17,16 @@
*/
typedef void (^RCTResponseSenderBlock)(NSArray *response);
/**
* This constant can be returned from +methodQueue to force module
* methods to be called on the JavaScript thread. This can have serious
* implications for performance, so only use this if you're sure it's what
* you need.
*
* NOTE: RCTJSThread is not a real libdispatch queue
*/
extern const dispatch_queue_t RCTJSThread;
/**
* Provides the interface needed to register a bridge module.
*/