Temporarily fix Flipper dev-mode webview crashes
Signed-off-by: Vitaliy Vlasov <siphiuel@gmail.com>
This commit is contained in:
parent
34755500d5
commit
ddbf7bc066
|
@ -303,9 +303,10 @@ dependencies {
|
||||||
debugImplementation("com.facebook.flipper:flipper:${FLIPPER_VERSION}") {
|
debugImplementation("com.facebook.flipper:flipper:${FLIPPER_VERSION}") {
|
||||||
exclude group:'com.facebook.fbjni'
|
exclude group:'com.facebook.fbjni'
|
||||||
}
|
}
|
||||||
debugImplementation("com.facebook.flipper:flipper-network-plugin:${FLIPPER_VERSION}") {
|
// TODO Uncomment once Flipper does not cause webview crashes in Debug mode
|
||||||
exclude group:'com.facebook.flipper'
|
// debugImplementation("com.facebook.flipper:flipper-network-plugin:${FLIPPER_VERSION}") {
|
||||||
}
|
// exclude group:'com.facebook.flipper'
|
||||||
|
// }
|
||||||
debugImplementation("com.facebook.flipper:flipper-fresco-plugin:${FLIPPER_VERSION}") {
|
debugImplementation("com.facebook.flipper:flipper-fresco-plugin:${FLIPPER_VERSION}") {
|
||||||
exclude group:'com.facebook.flipper'
|
exclude group:'com.facebook.flipper'
|
||||||
}
|
}
|
||||||
|
|
|
@ -15,8 +15,8 @@ import com.facebook.flipper.plugins.databases.DatabasesFlipperPlugin;
|
||||||
import com.facebook.flipper.plugins.fresco.FrescoFlipperPlugin;
|
import com.facebook.flipper.plugins.fresco.FrescoFlipperPlugin;
|
||||||
import com.facebook.flipper.plugins.inspector.DescriptorMapping;
|
import com.facebook.flipper.plugins.inspector.DescriptorMapping;
|
||||||
import com.facebook.flipper.plugins.inspector.InspectorFlipperPlugin;
|
import com.facebook.flipper.plugins.inspector.InspectorFlipperPlugin;
|
||||||
import com.facebook.flipper.plugins.network.FlipperOkhttpInterceptor;
|
// import com.facebook.flipper.plugins.network.FlipperOkhttpInterceptor;
|
||||||
import com.facebook.flipper.plugins.network.NetworkFlipperPlugin;
|
// import com.facebook.flipper.plugins.network.NetworkFlipperPlugin;
|
||||||
import com.facebook.flipper.plugins.react.ReactFlipperPlugin;
|
import com.facebook.flipper.plugins.react.ReactFlipperPlugin;
|
||||||
import com.facebook.flipper.plugins.sharedpreferences.SharedPreferencesFlipperPlugin;
|
import com.facebook.flipper.plugins.sharedpreferences.SharedPreferencesFlipperPlugin;
|
||||||
import com.facebook.react.ReactInstanceManager;
|
import com.facebook.react.ReactInstanceManager;
|
||||||
|
@ -35,15 +35,16 @@ public class ReactNativeFlipper {
|
||||||
client.addPlugin(new SharedPreferencesFlipperPlugin(context));
|
client.addPlugin(new SharedPreferencesFlipperPlugin(context));
|
||||||
client.addPlugin(CrashReporterPlugin.getInstance());
|
client.addPlugin(CrashReporterPlugin.getInstance());
|
||||||
|
|
||||||
NetworkFlipperPlugin networkFlipperPlugin = new NetworkFlipperPlugin();
|
// TODO Uncomment once Flipper does not cause webview crashes in Debug mode
|
||||||
NetworkingModule.setCustomClientBuilder(
|
// NetworkFlipperPlugin networkFlipperPlugin = new NetworkFlipperPlugin();
|
||||||
new NetworkingModule.CustomClientBuilder() {
|
// NetworkingModule.setCustomClientBuilder(
|
||||||
@Override
|
// new NetworkingModule.CustomClientBuilder() {
|
||||||
public void apply(OkHttpClient.Builder builder) {
|
// @Override
|
||||||
builder.addNetworkInterceptor(new FlipperOkhttpInterceptor(networkFlipperPlugin));
|
// public void apply(OkHttpClient.Builder builder) {
|
||||||
}
|
// builder.addNetworkInterceptor(new FlipperOkhttpInterceptor(networkFlipperPlugin));
|
||||||
});
|
// }
|
||||||
client.addPlugin(networkFlipperPlugin);
|
// });
|
||||||
|
// client.addPlugin(networkFlipperPlugin);
|
||||||
client.start();
|
client.start();
|
||||||
|
|
||||||
// Fresco Plugin needs to ensure that ImagePipelineFactory is initialized
|
// Fresco Plugin needs to ensure that ImagePipelineFactory is initialized
|
||||||
|
|
Loading…
Reference in New Issue