You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+31-23Lines changed: 31 additions & 23 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,4 +1,4 @@
1
-
This is demo repo is used by Solution Engineers when demo'ing Sentry's [React Native](https://docs.sentry.io/platforms/react-native) SDK's capabilties.
1
+
This is demo repo is used by Solution Engineers when demo'ing Sentry's [React Native](https://docs.sentry.io/platforms/react-native) SDK's capabilties.
@@ -7,8 +7,8 @@ This is demo repo is used by Solution Engineers when demo'ing Sentry's [React Na
7
7
8
8
## Versions
9
9
10
-
| dependency | version
11
-
| ------------- |:-------------:|
10
+
| dependency | version
11
+
| ------------- |:-------------:|
12
12
| react-native | 0.64.0 |
13
13
| gradle | 6.7 |
14
14
| react | 16.13.1 |
@@ -24,7 +24,7 @@ This step was already performed for adding the sdk to sentry_react_native, but i
24
24
```
25
25
$npx @sentry/wizard -i reactNative -p ios android
26
26
```
27
-
The above command launches the [Sentry wizard](https://github.com/getsentry/sentry-wizard) allowing you to [link](https://docs.sentry.io/platforms/react-native/#linking) with the correct Sentry react-native project.
27
+
The above command launches the [Sentry wizard](https://github.com/getsentry/sentry-wizard) allowing you to [link](https://docs.sentry.io/platforms/react-native/#linking) with the correct Sentry react-native project.
28
28
From our [documentation](https://docs.sentry.io/platforms/react-native/), the following changes happen which you should be aware of:
29
29
```
30
30
- add the sentry-android package for native crash reporting on Android
@@ -45,9 +45,9 @@ From our [documentation](https://docs.sentry.io/platforms/react-native/), the fo
45
45
6.`cd ios && pod install`
46
46
7.`npm install`
47
47
48
-
Don't forget to bump your release version depending on platform
49
-
iOS: `Info.plist``CFBundleShortVersionString`
50
-
android: `app.build.gradle``versionName`
48
+
Don't forget to bump your release version depending on platform
 | |
85
+
 | |
86
86
87
87
## Upgrade path
88
88
1. npm install, then `pod update` if `pod install` is failing. The pod updating depends on node_modules/@sentry/react-native being set.
89
89
2. SDK Manager -> install 'emulator' or anything missing
90
-
3. Review previous PR so you know what to expect
90
+
3. Review previous PR so you know what to expect
91
91
92
-
## Troubleshooting
92
+
## Troubleshooting
93
93
94
94
#### Repo
95
-
This repo borrowed from [original react-native repo ](https://github.com/sentry-demos/react-native/commit/269f58d63426065a4de67a3f22d2e774787cd996)
96
-
The following may have been borrowed: `package.json`, `package-lock.json`, `ios/Podfile`, `ios/Podfile.lock`, see [pull/2](https://github.com/sentry-demos/sentry_react_native/pull/2)
95
+
This repo borrowed from [original react-native repo ](https://github.com/sentry-demos/react-native/commit/269f58d63426065a4de67a3f22d2e774787cd996)
96
+
The following may have been borrowed: `package.json`, `package-lock.json`, `ios/Podfile`, `ios/Podfile.lock`, see [pull/2](https://github.com/sentry-demos/sentry_react_native/pull/2)
97
97
98
98
Please know that react-native generates it own [.gitignore file](https://stackoverflow.com/questions/49099131/recommended-gitignore-for-react-native/49099219
99
-
), which is of course part of this repo, so only those [autogenerated files](https://stackoverflow.com/questions/48448426/why-dont-we-gitignore-ios-and-android-in-react-native) that are required for a baseline setup and the original demo code (files) are part of this repo.
99
+
), which is of course part of this repo, so only those [autogenerated files](https://stackoverflow.com/questions/48448426/why-dont-we-gitignore-ios-and-android-in-react-native) that are required for a baseline setup and the original demo code (files) are part of this repo.
100
100
101
101
Please see [Steps](#what-were-the-steps-again) or go through the [first ten commits](https://github.com/sentry-demos/sentry_react_native/commits/master) (and their git log) messages in chronological order, to see the exact commands that were run and what files that were autogenerated.
102
102
@@ -117,10 +117,10 @@ pod install
117
117
```
118
118
119
119
#### adding Sentry for first time
120
-
When running npx @sentry/wizard -i reactNative -p ios android
121
-
At this point, you may get an error like:
122
-
`TypeError [ERR_INVALID_ARG_TYPE]: The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView. Received undefined`
123
-
It should be safe to look past this error. A minor issue is that it blocks creation of `ios/sentry.properties`. So simply make a copy of `android/sentry.properties` and put it in `ios/sentry.properties`:
120
+
When running npx @sentry/wizard -i reactNative -p ios android
121
+
At this point, you may get an error like:
122
+
`TypeError [ERR_INVALID_ARG_TYPE]: The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView. Received undefined`
123
+
It should be safe to look past this error. A minor issue is that it blocks creation of `ios/sentry.properties`. So simply make a copy of `android/sentry.properties` and put it in `ios/sentry.properties`:
124
124
```
125
125
cp andoid/sentry.properties ios/sentry.properties
126
126
cd ios
@@ -136,7 +136,7 @@ npx react-native eject
136
136
```
137
137
138
138
#### Emulators
139
-
When running emulator...
139
+
When running emulator...
140
140
If the app launches and suddenly crashes you may need to reinstall your node package with this command:
141
141
142
142
```
@@ -156,4 +156,12 @@ You may run into issues if you haven't added sdk and sdk platform-tools to path:
156
156
If tools don't load, then swipe-away (kill) the app, then relaunch from app menu in the emulator. If still fails, then go to AVD Manager and 'wipe' the device and run the emulator again.
157
157
Could also be a problem with the backend container/app you're requesting the tools from (check that URL/Postman, check TDA job)
158
158
159
-
When developing locally, must point React Native to http://127.0.0.1:8080/products backend instead of https://localhost:8080/products backend.
159
+
When developing locally, must point React Native to http://127.0.0.1:8080/products backend instead of https://localhost:8080/products backend.
160
+
161
+
162
+
## Creating release with APK + .app.zip for [Test-Data Automation](https://github.com/sentry-demos/application-monitoring/tree/master/tests)
163
+
164
+
First generate the apps using `npx react-native run-ios --configuration Release` for iOS, and `npx react-native run-android --variant Release` for Andriod
0 commit comments