react-native/ReactKit/Base/RCTJSMethodRegistrar.h
Christopher Chedeau c892d2c8d1 Updates from Tue Feb 24
- Only update Redbox when offscreen | Nick Lockwood
- [react-packager] Cleanup option passing and validation | Amjad Masad
- Unified bridge implementation between OSS and private React forks | Nick Lockwood
- [react-packager][cleanup options 1/2] add npm installed joi validation library | Amjad Masad
2015-02-25 12:40:49 -08:00

25 lines
802 B
Objective-C

// Copyright 2004-present Facebook. All Rights Reserved.
#import <Foundation/Foundation.h>
@class RCTBridge;
/**
* Provides an interface to register JS methods to be called via the bridge.
*/
@protocol RCTJSMethodRegistrar <NSObject>
@optional
/**
* An array of JavaScript methods that the class will call via the
* -[RCTBridge enqueueJSCall:args:] method. Each method should be specified
* as a string of the form "JSModuleName.jsMethodName". Attempting to call a
* method that has not been registered will result in an error. If a method
* has already been registered by another class, it is not necessary to
* register it again, but it is good practice. Registering the same method
* more than once is silently ignored and will not result in an error.
*/
+ (NSArray *)JSMethods;
@end