Skip to content

Commit

Permalink
[sample] Remove Flipper integration temporarily
Browse files Browse the repository at this point in the history
  • Loading branch information
passy committed Apr 25, 2024
1 parent dc22d91 commit 11ffd62
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 27 deletions.
3 changes: 0 additions & 3 deletions sample/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ dependencies {
implementation project(':litho-core')
implementation project(':litho-coroutines-kotlin')
implementation project(':litho-editor-core')
implementation project(':litho-editor-flipper')
implementation project(':litho-fresco')
implementation project(':litho-fresco-kotlin')
implementation project(':litho-live-data')
Expand All @@ -59,8 +58,6 @@ dependencies {

// First-party
implementation deps.soloader
implementation deps.flipper
implementation deps.flipperLithoPlugin
implementation deps.fresco
implementation deps.frescoVito
implementation deps.frescoVitoLitho
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,9 @@
package com.facebook.samples.litho;

import android.app.Application;

import com.facebook.drawee.backends.pipeline.Fresco;
import com.facebook.flipper.android.AndroidFlipperClient;
import com.facebook.flipper.android.utils.FlipperUtils;
import com.facebook.flipper.core.FlipperClient;
import com.facebook.flipper.plugins.inspector.DescriptorMapping;
import com.facebook.flipper.plugins.inspector.InspectorFlipperPlugin;
import com.facebook.flipper.plugins.sections.SectionsFlipperPlugin;
import com.facebook.flipper.plugins.uidebugger.UIDebuggerFlipperPlugin;
import com.facebook.flipper.plugins.uidebugger.core.UIDContext;
import com.facebook.flipper.plugins.uidebugger.litho.UIDebuggerLithoSupport;
import com.facebook.fresco.vito.init.FrescoVito;
import com.facebook.litho.editor.flipper.LithoFlipperDescriptors;
import com.facebook.rendercore.debug.DebugEventBus;
import com.facebook.rendercore.debug.DebugEventLogger;
import com.facebook.soloader.SoLoader;
Expand All @@ -44,19 +35,5 @@ public void onCreate() {
Fresco.initialize(this);
FrescoVito.initialize();
SoLoader.init(this, false);

if (FlipperUtils.shouldEnableFlipper(this)) {
final FlipperClient client = AndroidFlipperClient.getInstance(this);

UIDContext uiDebuggerContext = UIDContext.Companion.create(this);
UIDebuggerLithoSupport.INSTANCE.enable(uiDebuggerContext);
client.addPlugin(new UIDebuggerFlipperPlugin(uiDebuggerContext));

final DescriptorMapping descriptorMapping = DescriptorMapping.withDefaults();
LithoFlipperDescriptors.add(descriptorMapping);
client.addPlugin(new InspectorFlipperPlugin(this, descriptorMapping));
client.addPlugin(new SectionsFlipperPlugin(true));
client.start();
}
}
}

0 comments on commit 11ffd62

Please sign in to comment.