This repository has been archived by the owner on Jan 23, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #28 from taras-omelchuk/master
Dynamics SDK for React Native v12.0
- Loading branch information
Showing
379 changed files
with
19,504 additions
and
10,856 deletions.
There are no files selected for viewing
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
BUNDLE_PATH: "vendor/bundle" | ||
BUNDLE_FORCE_RUBY_PLATFORM: 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
16 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
module.exports = { | ||
arrowParens: 'avoid', | ||
bracketSameLine: true, | ||
bracketSpacing: false, | ||
jsxBracketSameLine: true, | ||
singleQuote: true, | ||
trailingComma: 'all', | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
2.7.5 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
source 'https://rubygems.org' | ||
|
||
# You may use http://rbenv.org/ or https://rvm.io/ to install and use this version | ||
ruby '2.7.5' | ||
|
||
gem 'cocoapods', '~> 1.11', '>= 1.11.2' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -44,18 +44,23 @@ Open the sample app directory in Terminal window: | |
Install dependencies: | ||
`$ yarn` | ||
|
||
NOTE: AppKinetics sample is based on `0.66.4` version of React Native. There is a possibility to upgrade to `0.67.x` or `0.68.x` versions (`0.67.0` - `0.67.4`, `0.68.0` - `0.68.2`) by running one of following commands: | ||
`$ react-native upgrade 0.6x.x` | ||
> NOTE: AppKinetics sample is based on `0.70.0` version of React Native. There is a possibility to upgrade to `0.70.x`, `0.71.x`, `0.72.x` versions (`0.70.1` - `0.70.10`, `0.71.0` - `0.71.13`, `0.72.0` - `0.72.4`) by running one of following commands: | ||
`$ npx react-native upgrade 0.70.x` | ||
for example: | ||
`$ react-native upgrade 0.67.4` | ||
`$ npx react-native upgrade 0.70.10` | ||
or | ||
`$ react-native upgrade 0.68.2` | ||
`$ npx react-native upgrade 0.71.13` | ||
or | ||
`$ npx react-native upgrade 0.72.4` | ||
|
||
Generate ios and android directories: | ||
`$ react-native eject` | ||
`$ npx react-native eject` | ||
|
||
Generate ios and android directories: | ||
`$ react-native eject` | ||
`$ npx react-native eject` | ||
|
||
> There is a known issue with loading Metro server on `0.72.0` and `0.72.1` versions when the error message is displayed during app load in Metro server: "Cannot read properties of undefined (reading 'addHelper')". The issue can be fixed by adding the following devDependency to the project: | ||
`$ yarn add @babel/[email protected] --dev` | ||
|
||
## Install Dynamics modules | ||
#### Prerequisites | ||
|
@@ -76,17 +81,23 @@ It is suggested to use **`com.blackberry.bbd.example.cdv.appkinetics.server`** h | |
$ yarn add <path>/modules/BlackBerry-Dynamics-for-React-Native-AppKinetics | ||
|
||
##### iOS | ||
Different `ruby` versions might be install on the machine. Especially it is related to React Native v`0.70.x` projects. | ||
Depending on your Mac configuration following error can occur when running `pod install` command: | ||
``` | ||
Traceback (most recent call last): | ||
4: from /Users/vtaliar/.rvm/gems/ruby-2.7.5/bin/ruby_executable_hooks:22:in `<main>' | ||
3: from /Users/vtaliar/.rvm/gems/ruby-2.7.5/bin/ruby_executable_hooks:22:in `eval' | ||
2: from /Users/vtaliar/.rvm/gems/ruby-2.7.5/bin/pod:23:in `<main>' | ||
1: from /Users/vtaliar/.rvm/rubies/ruby-2.7.5/lib/ruby/2.7.0/rubygems.rb:296:in `activate_bin_path' | ||
/Users/vtaliar/.rvm/rubies/ruby-2.7.5/lib/ruby/2.7.0/rubygems.rb:277:in `find_spec_for_exe': can't find gem cocoapods (>= 0.a) with executable pod (Gem::GemNotFoundException) | ||
``` | ||
More details can be found [here](https://medium.com/@pk60905/bundle-install-and-bundle-update-80f3d6f52214). | ||
|
||
`$ bundle install` - needed on some `0.70.x` versions to fix the issue above | ||
`$ cd ios` | ||
`$ pod install` | ||
`$ cd ..` | ||
|
||
#### How to run application | ||
##### iOS | ||
`$ react-native run-ios` | ||
|
||
##### Android | ||
`$ react-native run-android` | ||
|
||
#### How to secure FileSystem | ||
$ yarn add <path>/modules/BlackBerry-Dynamics-for-React-Native-FileSystem | ||
|
||
|
@@ -101,10 +112,10 @@ It is suggested to use **`com.blackberry.bbd.example.cdv.appkinetics.server`** h | |
|
||
#### How to run application | ||
##### iOS | ||
`$ react-native run-ios` | ||
`$ npx react-native run-ios` | ||
|
||
##### Android | ||
`$ react-native run-android` | ||
`$ npx react-native run-android` | ||
|
||
## Prepare files that will be sent to other app | ||
In order to send files to other Dynamics applications files need to be stored in appropriate location. | ||
|
@@ -136,29 +147,51 @@ Native Dynamics AppKinetics sample is a service provider of **`transfer-file`** | |
4. Install and activate | ||
|
||
## Examples of usage | ||
##### 0.66.4 | ||
##### 0.70.0 | ||
`$ cd <path>/SampleApplications/AppKinetics` | ||
`$ yarn` | ||
`$ react-native eject` | ||
`$ git init` | ||
`$ npx react-native eject` | ||
`$ yarn add <path>/modules/BlackBerry-Dynamics-for-React-Native-Base` | ||
`$ yarn set-bundle-id` | ||
It is suggested to use **`com.blackberry.bbd.example.cdv.appkinetics.client`** here. An app with this ID is already configured on UEM as a service provider of **`transfer-file`** service, so it can both send and receive files. | ||
`$ yarn add <path>/modules/BlackBerry-Dynamics-for-React-Native-AppKinetics` | ||
`$ yarn add <path>/modules/BlackBerry-Dynamics-for-React-Native-FileSystem` | ||
`$ yarn add <path>/modules/BlackBerry-Dynamics-for-React-Native-Networking` | ||
For iOS: | ||
For iOS: | ||
`$ bundle install` | ||
`$ cd ios` | ||
`$ pod install` | ||
`$ cd ..` | ||
`$ npx react-native run-ios` | ||
For Android: | ||
`$ npx react-native run-android` | ||
##### 0.70.10 | ||
`$ cd <path>/SampleApplications/AppKinetics` | ||
`$ yarn` | ||
`$ git init` | ||
`$ npx react-native upgrade 0.70.10` | ||
`$ npx react-native eject` | ||
`$ yarn add <path>/modules/BlackBerry-Dynamics-for-React-Native-Base` | ||
`$ yarn set-bundle-id` | ||
It is suggested to use **`com.blackberry.bbd.example.cdv.appkinetics.client`** here. An app with this ID is already configured on UEM as a service provider of **`transfer-file`** service, so it can both send and receive files. | ||
`$ yarn add <path>/modules/BlackBerry-Dynamics-for-React-Native-AppKinetics` | ||
`$ yarn add <path>/modules/BlackBerry-Dynamics-for-React-Native-FileSystem` | ||
`$ yarn add <path>/modules/BlackBerry-Dynamics-for-React-Native-Networking` | ||
For iOS: | ||
`$ cd ios` | ||
`$ pod install` | ||
`$ cd ..` | ||
`$ react-native run-ios` | ||
`$ npx react-native run-ios` | ||
For Android: | ||
`$ react-native run-android` | ||
##### 0.68.2 | ||
`$ npx react-native run-android` | ||
##### 0.72.0 | ||
`$ cd <path>/SampleApplications/AppKinetics` | ||
`$ yarn` | ||
`$ cd .. ; git init ; cd AppKinetics` | ||
`$ react-native upgrade 0.68.2` | ||
`$ react-native eject` | ||
`$ yarn add @babel/[email protected] --dev` - OPTIONAL: needed on `0.72.0`, `0.72.1` versions to fix the error mentioned above in Metro server | ||
`$ git init` | ||
`$ npx react-native upgrade 0.72.0` | ||
`$ npx react-native eject` | ||
`$ yarn add <path>/modules/BlackBerry-Dynamics-for-React-Native-Base` | ||
`$ yarn set-bundle-id` | ||
It is suggested to use **`com.blackberry.bbd.example.cdv.appkinetics.client`** here. An app with this ID is already configured on UEM as a service provider of **`transfer-file`** service, so it can both send and receive files. | ||
|
@@ -169,6 +202,6 @@ For iOS: | |
`$ cd ios` | ||
`$ pod install` | ||
`$ cd ..` | ||
`$ react-native run-ios` | ||
`$ npx react-native run-ios` | ||
For Android: | ||
`$ react-native run-android` | ||
`$ npx react-native run-android` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
BUNDLE_PATH: "vendor/bundle" | ||
BUNDLE_FORCE_RUBY_PLATFORM: 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
module.exports = { | ||
root: true, | ||
extends: '@react-native-community', | ||
}; |
Oops, something went wrong.