Skip to content

Commit fbe920f

Browse files
authored
Update readme to advise on react-native-windows versioning (#189)
As `react-native-windows` is not keeping pace with `react-native` we will have to advise users in the README. Also, update some of the steps to create your own application with `react-native-pspdfkit`.
1 parent a5e24ca commit fbe920f

File tree

1 file changed

+18
-15
lines changed

1 file changed

+18
-15
lines changed

README.md

Lines changed: 18 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -621,6 +621,8 @@ Shows the pdf `document` from the local device filesystem, or your app's assets.
621621
- PSPDFKit for Windows.vsix (installed)
622622
- PowerShell
623623
624+
*IMPORTANT* : `react-native-pspdfkit` for windows does not yet support react-native 0.59.\*. Currently [`react-native-windows`][https://github.com/Microsoft/react-native-windows/releases] is not keeping up pace with `react-native`, where the last official release was 0.54.\* and the last RC was 0.57.\*. We have tested and require 0.57.0 to keep version aligned as much as possible.
625+
624626
#### Getting Started
625627
626628
Let's create a simple app that integrates PSPDFKit and uses the react-native-pspdfkit module.
@@ -629,22 +631,23 @@ Let's create a simple app that integrates PSPDFKit and uses the react-native-psp
629631
2. Make sure `react-native-cli` is installed: `yarn global add react-native-cli`.
630632
3. Install Windows Tool for React Native: `yarn add global windows-build-tools`.
631633
4. Open `x64 Native Tools Command Prompt for VS 2017` program.
632-
5. Create the app with `react-native init --version=0.55.4 YourApp` in a location of your choice.
634+
5. Create the app with `react-native init --version=0.57.8 YourApp` in a location of your choice.
633635
6. Step into your newly created app folder: `cd YourApp`.
634636
7. Install the Windows helper plugin: `yarn add --dev rnpm-plugin-windows`.
635-
8. Install `react-native-pspdfkit` from GitHub: `yarn add github:PSPDFKit/react-native`.
637+
8. Install `react-native-pspdfkit` from GitHub: `yarn add github:PSPDFKit/react-native#windows-1.11.0`.
636638
9. Install `react-native-fs` from GitHub: `yarn add react-native-fs`.
637639
10. Install all modules for Windows: `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.)
638640
11. Initialize the windows project: `react-native windows`.
639641
12. Link module `react-native-pspdfkit`: `react-native link react-native-pspdfkit`.
640-
13. Open the Visual Studio solution in `react-native\YourApp\windows`.
641-
14. Accept and install any required extensions when prompted.
642-
15. If the settings window opens, click on `Developer` and select `yes`.
643-
16. Mark `PSPDFKit SDK` and `Visual C++ Runtime` as dependencies for `YourApp`:
642+
13. Link module `react-native-fs`: `react-native link react-native-fs`.
643+
14. Open the Visual Studio solution in `react-native\YourApp\windows`.
644+
15. Accept and install any required extensions when prompted.
645+
16. If the settings window opens, click on `Developer` and select `yes`.
646+
17. Mark `PSPDFKit SDK` and `Visual C++ Runtime` as dependencies for `YourApp`:
644647
Right click on `YourApp` -> Add -> Refererece... Click on Projects and tick `ReactNativePSPDFKit`. Click on Universal Windows -> Extensions and tick `PSPDFKit for UWP` and `Visual C++ 2015 Runtime for Universal Windows Platform Apps` then click ok.
645648
![Add References Selection](screenshots/windowsAddReferences.PNG)
646649
![Reference Checkboxes](screenshots/windowsSelectPSPDFKit+UWP.PNG)
647-
17. Add an application resource to your `Appl.xaml` to reference your License key.
650+
18. Add an application resource to your `Appl.xaml` to reference your License key.
648651
649652
```diff
650653
<rn:ReactApplication
@@ -665,7 +668,7 @@ Let's create a simple app that integrates PSPDFKit and uses the react-native-psp
665668
</rn:ReactApplication>
666669
```
667670
668-
18. Create a new file resource called `License.xaml` with your PSPDFKit license key at the top level of the
671+
19. Create a new file resource called `License.xaml` with your PSPDFKit license key at the top level of the
669672
project. (Replace `ENTER LICENSE KEY HERE` with your key)
670673
671674
```xaml
@@ -678,11 +681,11 @@ Let's create a simple app that integrates PSPDFKit and uses the react-native-psp
678681
</ResourceDictionary>
679682
```
680683
681-
19. Change the target SDK of YourApp to >= 10.0.16299 and Min Version to >= 10.0.15063 : Right Click on YourApp -> Properties. Go to
682-
Application and change Target Version to >= 10.0.16299 and change Min Version to >= 10.0.15063.
684+
20. Change the target SDK of YourApp to >= 10.0.17134 and Min Version to >= 10.0.15063 : Right Click on YourApp -> Properties. Go to
685+
Application and change Target Version to >= 10.0.17134 and change Min Version to >= 10.0.15063.
683686
![Change SDK Version](screenshots/changeVersionSDK.png)
684-
20. Save Changes: File -> Save All
685-
21. Add the `PSPDFKitView` and `PSPDFKit` module into your `App.windows.js` file, and add a open button to allow the user
687+
21. Save Changes: File -> Save All
688+
22. Add the `PSPDFKitView` and `PSPDFKit` module into your `App.windows.js` file, and add a open button to allow the user
686689
to navigate the file system.
687690
688691
```javascript
@@ -746,9 +749,9 @@ var styles = StyleSheet.create({
746749
});
747750
```
748751
749-
22. Now run the application on the command line: `react-native run-windows`.
750-
23. Press Yes when PowerShell wants to run.
751-
24. Type 'y' when asking if you want to install the certificate.
752+
23. Now run the application on the command line: `react-native run-windows`.
753+
24. Press Yes when PowerShell wants to run.
754+
25. Type 'y' when asking if you want to install the certificate.
752755
753756
#### Running Catalog Project
754757

0 commit comments

Comments
 (0)