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
@@ -257,9 +257,10 @@ Let's create a simple app that integrates PSPDFKit and uses the react-native-psp
257
257
1. Make sure `react-native-cli` is installed: `yarn global add react-native-cli`
258
258
2. Create the app with `react-native init YourApp`.
259
259
3. Step into your newly created app folder: `cd YourApp`.
260
-
4. Install `react-native-pspdfkit` from GitHub: `yarn add github:PSPDFKit/react-native`.
261
-
5. Link module `react-native-pspdfkit`: `react-native link react-native-pspdfkit`.
262
-
6. <aid="step-6"></a>Add PSPDFKit and Google repository to `YourApp/android/build.gradle` so PSPDFKit library and Android dependencies can be downloaded:
260
+
4. Add `react-native-pspdfkit` module from GitHub: `yarn add github:PSPDFKit/react-native`.
261
+
5. Install all the dependencies for the project: `yarn install`. (Because of a [bug](https://github.com/yarnpkg/yarn/issues/2165) you may need to clean `yarn`'s cache with `yarn cache clean` before.)
262
+
6. Link module `react-native-pspdfkit`: `react-native link react-native-pspdfkit`.
263
+
7. <aid="step-6"></a>Add PSPDFKit and Google repository to `YourApp/android/build.gradle` so PSPDFKit library and Android dependencies can be downloaded:
263
264
264
265
```diff
265
266
allprojects {
@@ -285,7 +286,7 @@ Let's create a simple app that integrates PSPDFKit and uses the react-native-psp
285
286
}
286
287
```
287
288
288
-
7. PSPDFKit targets modern platforms, so you'll have to update `compileSdkVersion` and `targetSdkVersion` to at least API 26 and enable MultiDex. In `YourApp/android/app/build.gradle` (note **five** places to edit):
289
+
8. PSPDFKit targets modern platforms, so you'll have to update `compileSdkVersion` and `targetSdkVersion` to at least API 26 and enable MultiDex. In `YourApp/android/app/build.gradle` (note **five** places to edit):
289
290
290
291
```diff
291
292
...
@@ -311,7 +312,7 @@ Let's create a simple app that integrates PSPDFKit and uses the react-native-psp
311
312
...
312
313
```
313
314
314
-
8. <aid="step-8"></a>Enter your PSPDFKit license key into `YourApp/android/app/src/main/AndroidManifest.xml` file:
315
+
9. <aid="step-8"></a>Enter your PSPDFKit license key into `YourApp/android/app/src/main/AndroidManifest.xml` file:
315
316
316
317
```diff
317
318
<application>
@@ -324,15 +325,15 @@ Let's create a simple app that integrates PSPDFKit and uses the react-native-psp
324
325
</application>
325
326
```
326
327
327
-
9. Set primary color. In `YourApp/android/app/src/main/res/values/styles.xml` replace
328
+
10. Set primary color. In `YourApp/android/app/src/main/res/values/styles.xml` replace
328
329
```xml
329
330
<!-- Customize your theme here. -->
330
331
```
331
332
with
332
333
```xml
333
334
<itemname="colorPrimary">#3C97C9</item>
334
335
```
335
-
10. <aid="step-10"></a>Replace the default component from `YourApp/App.js` with a simple touch area to present a PDF document from the local device filesystem:
336
+
11. <aid="step-10"></a>Replace the default component from `YourApp/App.js` with a simple touch area to present a PDF document from the local device filesystem:
336
337
337
338
```javascript
338
339
importReact, { Component } from'react';
@@ -403,13 +404,13 @@ with
403
404
}
404
405
});
405
406
```
406
-
11. Before launching the app you need to copy a PDF document onto your development device or emulator.
407
+
12. Before launching the app you need to copy a PDF document onto your development device or emulator.
0 commit comments