Skip to content

Commit 0a9ddb1

Browse files
committed
fix: Update README with new instructions
1 parent 154bda8 commit 0a9ddb1

File tree

1 file changed

+7
-17
lines changed

1 file changed

+7
-17
lines changed

README.md

Lines changed: 7 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -2,24 +2,13 @@
22

33
WhatTheStack is a library to make your debugging experience on Android better.
44

5-
WhatTheStack shows you a pretty error screen when your Android App crashes, instead of a boring old dialog saying "Unfortunately, \<your-app\> has crashed".
5+
It shows you a pretty error screen when your Android App crashes, instead of a boring old dialog saying "Unfortunately, \<your-app\> has crashed".
66

77
## Setup
88

9-
All that is needed to initialize this library is to use the `init()` method in the `onCreate()` callback of your custom Application class.
9+
WhatTheStack initializes automatically when your app starts. Just follow the [Installation Instructions](#installation) to set it up.
1010

11-
```kotlin
12-
class MyApp : Application() {
13-
override fun onCreate() {
14-
super.onCreate()
15-
if (BuildConfig.DEBUG) {
16-
WhatTheStack(this).init()
17-
}
18-
}
19-
}
20-
```
21-
22-
And when an error is thrown in your application, you shall be greeted with a screen similar to this:
11+
Now when an uncaught exception is thrown in your application, you shall be greeted with a screen similar to this:
2312

2413
<img src="media/screenshot.jpeg" width="360px" height="640px"/>
2514

@@ -38,20 +27,21 @@ Add Jitpack repository in your root `build.gradle` file:
3827
```groovy
3928
allprojects {
4029
repositories {
41-
...
4230
maven { url 'https://jitpack.io' }
43-
}
31+
}
4432
}
4533
```
4634

4735
And then add the dependency to your app:
4836

4937
```groovy
5038
dependencies {
51-
implementation 'com.github.haroldadmin:WhatTheStack:(latest-version)'
39+
debugImplementation 'com.github.haroldadmin:WhatTheStack:(latest-version)'
5240
}
5341
```
5442

43+
It is not recommended to use WhatTheStack in anything other than debug builds of your app. Only use `debugImplementation` when adding this dependency.
44+
5545
[![Release](https://jitpack.io/v/haroldadmin/WhatTheStack.svg)](https://jitpack.io/#haroldadmin/WhatTheStack)
5646

5747
## Contributions

0 commit comments

Comments
 (0)