Skip to content

Instantly share code, notes, and snippets.

@Dhaval2404
Created October 6, 2016 20:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Dhaval2404/c0bdeb0312dc73d62c5396467e58f071 to your computer and use it in GitHub Desktop.
Save Dhaval2404/c0bdeb0312dc73d62c5396467e58f071 to your computer and use it in GitHub Desktop.
//In Application Class
@Override
public void onCreate() {
super.onCreate();
Stetho.InitializerBuilder initializerBuilder =
Stetho.newInitializerBuilder(this);
// Enable Chrome DevTools
initializerBuilder.enableWebKitInspector(
Stetho.defaultInspectorModulesProvider(this)
);
// Enable command line interface
initializerBuilder.enableDumpapp(
Stetho.defaultDumperPluginsProvider(this)
);
// Use the InitializerBuilder to generate an Initializer
Stetho.Initializer initializer = initializerBuilder.build();
// Initialize Stetho with the Initializer
Stetho.initialize(initializer);
}
//In app.gradle
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'com.facebook.stetho:stetho:1.3.1'
compile 'com.facebook.stetho:stetho-urlconnection:1.3.1'
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment