mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-04-29 21:46:07 +08:00
Delete RCTBatchedBridge
Summary: I've talked to several major community users, and they're all ok with deleting this code. There's several doc fixes which will make it easier for third party developers which should land about the same time this will. Also buried along with it is RCTJSCExecutor. Reviewed By: javache Differential Revision: D6880781 fbshipit-source-id: b4cb1143def6fd23a96290e478fa728adbedacd3
This commit is contained in:
committed by
Facebook Github Bot
parent
108f9664bf
commit
816d417189
@@ -52,9 +52,6 @@
|
||||
#import "RCTDevLoadingView.h"
|
||||
#endif
|
||||
|
||||
@interface RCTCxxBridge : RCTBridge
|
||||
@end
|
||||
|
||||
#define RCTAssertJSThread() \
|
||||
RCTAssert(self.executorClass || self->_jsThread == [NSThread currentThread], \
|
||||
@"This method must be called on JS thread")
|
||||
@@ -522,11 +519,6 @@ struct RCTInstanceCallback : public InstanceCallback {
|
||||
RCT_PROFILE_END_EVENT(RCTProfileTagAlways, @"");
|
||||
}
|
||||
|
||||
- (NSArray *)configForModuleName:(NSString *)moduleName
|
||||
{
|
||||
return _moduleDataByName[moduleName].config;
|
||||
}
|
||||
|
||||
- (NSArray<RCTModuleData *> *)registerModulesForClasses:(NSArray<Class> *)moduleClasses
|
||||
{
|
||||
RCT_PROFILE_BEGIN_EVENT(RCTProfileTagAlways,
|
||||
@@ -536,13 +528,6 @@ struct RCTInstanceCallback : public InstanceCallback {
|
||||
for (Class moduleClass in moduleClasses) {
|
||||
NSString *moduleName = RCTBridgeModuleNameForClass(moduleClass);
|
||||
|
||||
// Don't initialize the old executor in the new bridge.
|
||||
// TODO mhorowitz #10487027: after D3175632 lands, we won't need
|
||||
// this, because it won't be eagerly initialized.
|
||||
if ([moduleName isEqualToString:@"RCTJSCExecutor"]) {
|
||||
continue;
|
||||
}
|
||||
|
||||
// Check for module name collisions
|
||||
RCTModuleData *moduleData = _moduleDataByName[moduleName];
|
||||
if (moduleData) {
|
||||
@@ -685,7 +670,7 @@ struct RCTInstanceCallback : public InstanceCallback {
|
||||
|
||||
- (void)_prepareModulesWithDispatchGroup:(dispatch_group_t)dispatchGroup
|
||||
{
|
||||
RCT_PROFILE_BEGIN_EVENT(0, @"-[RCTBatchedBridge prepareModulesWithDispatch]", nil);
|
||||
RCT_PROFILE_BEGIN_EVENT(0, @"-[RCTCxxBridge _prepareModulesWithDispatchGroup]", nil);
|
||||
|
||||
BOOL initializeImmediately = NO;
|
||||
if (dispatchGroup == NULL) {
|
||||
|
||||
Reference in New Issue
Block a user