Skip to content

Instantly share code, notes, and snippets.

View jboxx's full-sized avatar
🇮🇩
Shut up! I am PRO

Rifqi Fardi Pradhana jboxx

🇮🇩
Shut up! I am PRO
View GitHub Profile
@jboxx
jboxx / StethoRealmApplication.java
Created September 29, 2018 19:22
Stetho Realm Application
public class StethoRealmApplication extends Application {
@Override
public void onCreate() {
super.onCreate();
Stetho.initialize(Stetho.newInitializerBuilder(this)
.enableDumpapp(Stetho.defaultDumperPluginsProvider(this))
.enableWebKitInspector(RealmInspectorModulesProvider.builder(this)
.databaseNamePattern(Pattern.compile(".+\\.realm")).build())
.build());
}
@jboxx
jboxx / stetho-realm.gradle
Created September 29, 2018 19:03
stetho realm
repositories {
maven { url 'https://github.com/uPhyca/stetho-realm/raw/master/maven-repo' }
}
dependencies {
implementation 'com.uphyca:stetho_realm:2.1.0'
}
@jboxx
jboxx / OkHttpStethoInterceptor.java
Created September 29, 2018 18:44
OkHttp Stetho Interceptor
OkHttpClient okHttpClient = new OkHttpClient.Builder()
.readTimeout(60, TimeUnit.SECONDS)
.connectTimeout(60, TimeUnit.SECONDS)
.addNetworkInterceptor(new StethoInterceptor())
.build();
@jboxx
jboxx / StethoDefaultApplication.java
Last active September 29, 2018 18:36
Stetho Default Application
public class StethoDefaultApplication extends Application {
@Override
public void onCreate() {
super.onCreate();
Stetho.initializeWithDefaults(this);
}
}
@jboxx
jboxx / stetho-okhttp.gradle
Last active September 29, 2018 19:01
stetho-okhttp
dependencies {
implementation 'com.facebook.stetho:stetho-okhttp:1.5.0'
}
@jboxx
jboxx / stetho-okhttp3.gradle
Last active September 29, 2018 19:04
stetho-okhttp3
dependencies {
implementation 'com.facebook.stetho:stetho-okhttp3:1.5.0'
}
@jboxx
jboxx / stetho.xml
Last active September 29, 2018 17:55
maven-stetho
<dependency>
<groupid>com.facebook.stetho</groupid>
<artifactid>stetho</artifactid>
<version>1.5.0</version>
</dependency>
@jboxx
jboxx / stetho.gradle
Last active September 29, 2018 19:04
gradle stetho
dependencies {
implementation 'com.facebook.stetho:stetho:1.5.0'
}
@jboxx
jboxx / .eslintrc
Last active December 19, 2017 12:30 — forked from radiovisual/.eslintrc
React Native AirBnB ESLint Config
{
"parser": "babel-eslint",
"plugins": [
"react",
"react-native"
],
"parserOptions": {
"ecmaFeatures": {
"jsx": true,
"modules": true
@jboxx
jboxx / MainScript.java
Last active November 14, 2016 03:32
My college assignment week 10. OOP example
interface DataInfo{
public void showInfo();
}
abstract class Siswa implements DataInfo{
private String nama;
private int nilai;
public Siswa(String nama, int nilai){
this.nama = nama;