mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-03-30 17:33:21 +08:00
Integrating AutoUpdater's custom JS Bundle loading into Fb4a
Reviewed By: AaaChiuuu Differential Revision: D3558831 fbshipit-source-id: b3909de774922fae903f3e8718fbfcd9b1ece2f8
This commit is contained in:
committed by
Facebook Github Bot 1
parent
e27c1495bd
commit
4ccd14f31a
@@ -127,6 +127,11 @@ public abstract class ReactInstanceManager {
|
||||
*/
|
||||
public abstract String getSourceUrl();
|
||||
|
||||
/**
|
||||
* The JS Bundle file that this Instance Manager was constructed with.
|
||||
*/
|
||||
public abstract @Nullable String getJSBundleFile();
|
||||
|
||||
/**
|
||||
* Attach given {@param rootView} to a catalyst instance manager and start JS application using
|
||||
* JS module provided by {@link ReactRootView#getJSModuleName}. If the react context is currently
|
||||
|
||||
@@ -629,6 +629,11 @@ import static com.facebook.react.bridge.ReactMarkerConstants.RUN_JS_BUNDLE_START
|
||||
return Assertions.assertNotNull(mSourceUrl);
|
||||
}
|
||||
|
||||
@Override
|
||||
public @Nullable String getJSBundleFile() {
|
||||
return mJSBundleFile;
|
||||
}
|
||||
|
||||
/**
|
||||
* Attach given {@param rootView} to a catalyst instance manager and start JS application using
|
||||
* JS module provided by {@link ReactRootView#getJSModuleName}. If the react context is currently
|
||||
|
||||
@@ -610,6 +610,14 @@ import static com.facebook.systrace.Systrace.TRACE_TAG_REACT_JAVA_BRIDGE;
|
||||
return Assertions.assertNotNull(mSourceUrl);
|
||||
}
|
||||
|
||||
@Override
|
||||
public @Nullable String getJSBundleFile() {
|
||||
if (mBundleLoader == null) {
|
||||
return null;
|
||||
}
|
||||
return mBundleLoader.getSourceUrl();
|
||||
}
|
||||
|
||||
/**
|
||||
* Attach given {@param rootView} to a catalyst instance manager and start JS application using
|
||||
* JS module provided by {@link ReactRootView#getJSModuleName}. If the react context is currently
|
||||
|
||||
Reference in New Issue
Block a user