File tree 3 files changed +35
-0
lines changed
3 files changed +35
-0
lines changed Original file line number Diff line number Diff line change @@ -11,6 +11,19 @@ yarn add react-native-sha256
11
11
react-native link
12
12
```
13
13
14
+ ## Adding with CocoaPods
15
+
16
+ Add the RNSha256 pod to your list of application pods in your Podfile, using the path from the Podfile to the installed module:
17
+
18
+ ```
19
+ pod 'RNSha256', :path => '../node_modules/react-native-sha256'
20
+ ```
21
+
22
+ Install pods as usual:
23
+ ```
24
+ pod install
25
+ ```
26
+
14
27
# Usage
15
28
16
29
Import the lib into your project:
Original file line number Diff line number Diff line change
1
+ require "json"
2
+
3
+ package = JSON . parse ( File . read ( File . join ( __dir__ , "package.json" ) ) )
4
+
5
+ Pod ::Spec . new do |s |
6
+ s . name = 'RNSha256'
7
+ s . version = package [ "version" ]
8
+ s . summary = package [ "description" ]
9
+ s . author = package [ "author" ]
10
+
11
+ s . homepage = package [ "homepage" ]
12
+
13
+ s . license = package [ "license" ]
14
+ s . platform = :ios , "8.0"
15
+
16
+ s . source = { :git => "https://github.com/itinance/react-native-sha256.git" , :tag => "#{ s . version } " }
17
+ s . source_files = "ios/**/*.{h,m,swift}"
18
+ s . preserve_paths = "**/*.js"
19
+
20
+ s . dependency 'React'
21
+ end
Original file line number Diff line number Diff line change 7
7
"test" : " echo \" Error: no test specified\" && exit 1" ,
8
8
"flow" : " flow; test $? -eq 0 -o $? -eq 2"
9
9
},
10
+ "homepage" : " https://github.com/itinance/react-native-sha256" ,
10
11
"repository" : {
11
12
"type" : " git" ,
12
13
"url" : " git@github.com:itinance/react-native-sha256.git"
You can’t perform that action at this time.
0 commit comments