Skip to content

Commit fdba80f

Browse files
author
Ali Abdelfattah
authored
Update README.md
1 parent b2c2b47 commit fdba80f

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

README.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -106,25 +106,23 @@ Alternatively, for iOS you can use [CocoaPods](https://cocoapods.org/) for manag
106106
* Make sure to import the package class:
107107
`import com.instabug.reactlibrary.RNInstabugReactnativePackage;`
108108
* **For React Native >= 0.60**
109-
Add the above integration code to the `onCreate()` method instead:
110-
109+
Add the integration code to the `onCreate()` method like the below snippet.
110+
111111
```java
112-
@Override
113-
public void onCreate() {
112+
@Override
113+
public void onCreate() {
114+
super.onCreate();
114115
new RNInstabugReactnativePackage
115116
.Builder("APP_TOKEN", MainApplication.this)
116117
.setInvocationEvent("shake")
117118
.setPrimaryColor("#1D82DC")
118119
.setFloatingEdge("left")
119120
.setFloatingButtonOffsetFromTop(250)
120121
.build();
121-
super.onCreate();
122-
SoLoader.init(this, /* native exopackage */ false);
123-
}
122+
}
124123
```
125124
* **For React Native < 0.60**
126-
You should find the `getPackages()` method looks like the following snippet. You just need to add your Android app token. You can change the invocation event from here, simply by replacing the `"shake"` with any of the following `"button"`, `"none"`, `"screenshot"`, or `"swipe"`. You can change the primary color by replacing the `"#1D82DC"` with any colour of your choice.
127-
In the case that you are using the floating button as an invocation event, you can change the floating button edge and the floating button offset using the last two methods, by replacing `"left"` to `"right"`, and by changing the offset number.
125+
You should find the `getPackages()` method looks like the below snippet. You just need to add your Android app token.
128126
129127
```javascript
130128
@Override
@@ -139,7 +137,9 @@ Alternatively, for iOS you can use [CocoaPods](https://cocoapods.org/) for manag
139137
.build()
140138
}
141139
```
142-
140+
* You can change the invocation event from here, simply by replacing the `"shake"` with any of the following `"button"`, `"none"`, `"screenshot"`, or `"swipe"`. You can change the primary color by replacing the `"#1D82DC"` with any color of your choice.
141+
In the case that you are using the floating button as an invocation event, you can change the floating button edge and the floating button offset using the last two methods, by replacing `"left"` to `"right"`, and by changing the offset number.
142+
143143
You can find your app token by selecting the SDK tab from your [**Instabug dashboard**](https://dashboard.instabug.com/app/sdk/).
144144
145145
4. Make sure the following snippet is added to your project level `build.gradle`. This should be added automatically upon linking. If not, you can add it manually.

0 commit comments

Comments
 (0)