Sfoglia il codice sorgente

Update example RN version

Mathieu Acthernoene 5 anni fa
parent
commit
9c3a9070d0
64 ha cambiato i file con 5742 aggiunte e 2307 eliminazioni
  1. 0
    3
      example/.babelrc
  2. 0
    6
      example/.buckconfig
  3. 0
    48
      example/.flowconfig
  4. 0
    53
      example/.gitignore
  5. 0
    1
      example/.watchmanconfig
  6. 34
    35
      example/App.js
  7. 0
    10
      example/__tests__/index.js
  8. 6
    16
      example/android/app/BUCK
  9. 75
    15
      example/android/app/build.gradle
  10. 19
    0
      example/android/app/build_defs.bzl
  11. 0
    60
      example/android/app/proguard-rules.pro
  12. 8
    0
      example/android/app/src/debug/AndroidManifest.xml
  13. 4
    8
      example/android/app/src/main/AndroidManifest.xml
  14. 2
    2
      example/android/app/src/main/java/com/rnpermissionsexample/MainActivity.java
  15. 10
    6
      example/android/app/src/main/java/com/rnpermissionsexample/MainApplication.java
  16. BIN
      example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png
  17. BIN
      example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png
  18. BIN
      example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png
  19. BIN
      example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png
  20. BIN
      example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png
  21. BIN
      example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
  22. BIN
      example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
  23. BIN
      example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
  24. BIN
      example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
  25. BIN
      example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
  26. 1
    1
      example/android/app/src/main/res/values/strings.xml
  27. 1
    0
      example/android/app/src/main/res/values/styles.xml
  28. 17
    3
      example/android/build.gradle
  29. 2
    1
      example/android/gradle.properties
  30. BIN
      example/android/gradle/wrapper/gradle-wrapper.jar
  31. 1
    1
      example/android/gradle/wrapper/gradle-wrapper.properties
  32. 59
    35
      example/android/gradlew
  33. 20
    10
      example/android/gradlew.bat
  34. 0
    8
      example/android/keystores/BUCK
  35. 0
    4
      example/android/keystores/debug.keystore.properties
  36. 2
    2
      example/android/settings.gradle
  37. 2
    2
      example/app.json
  38. 3
    0
      example/babel.config.js
  39. 8
    3
      example/index.js
  40. 0
    24
      example/ios/Example-tvOSTests/Info.plist
  41. 0
    1525
      example/ios/Example.xcodeproj/project.pbxproj
  42. 0
    129
      example/ios/Example.xcodeproj/xcshareddata/xcschemes/Example-tvOS.xcscheme
  43. 0
    16
      example/ios/Example/AppDelegate.h
  44. 0
    37
      example/ios/Example/AppDelegate.m
  45. 0
    83
      example/ios/Example/Info.plist
  46. 0
    18
      example/ios/Example/main.m
  47. 0
    70
      example/ios/ExampleTests/ExampleTests.m
  48. 0
    24
      example/ios/ExampleTests/Info.plist
  49. 32
    0
      example/ios/Podfile
  50. 193
    0
      example/ios/Podfile.lock
  51. 405
    0
      example/ios/RNPermissionsExample.xcodeproj/project.pbxproj
  52. 19
    19
      example/ios/RNPermissionsExample.xcodeproj/xcshareddata/xcschemes/RNPermissionsExample.xcscheme
  53. 10
    0
      example/ios/RNPermissionsExample.xcworkspace/contents.xcworkspacedata
  54. 8
    0
      example/ios/RNPermissionsExample.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
  55. 15
    0
      example/ios/RNPermissionsExample/AppDelegate.h
  56. 42
    0
      example/ios/RNPermissionsExample/AppDelegate.m
  57. 1
    1
      example/ios/RNPermissionsExample/Base.lproj/LaunchScreen.xib
  58. 0
    0
      example/ios/RNPermissionsExample/Images.xcassets/AppIcon.appiconset/Contents.json
  59. 0
    0
      example/ios/RNPermissionsExample/Images.xcassets/Contents.json
  60. 18
    15
      example/ios/RNPermissionsExample/Info.plist
  61. 16
    0
      example/ios/RNPermissionsExample/main.m
  62. 10
    0
      example/metro.config.js
  63. 10
    13
      example/package.json
  64. 4689
    0
      example/yarn.lock

+ 0
- 3
example/.babelrc Vedi File

@@ -1,3 +0,0 @@
1
-{
2
-  "presets": ["react-native"]
3
-}

+ 0
- 6
example/.buckconfig Vedi File

@@ -1,6 +0,0 @@
1
-
2
-[android]
3
-  target = Google Inc.:Google APIs:23
4
-
5
-[maven_repositories]
6
-  central = https://repo1.maven.org/maven2

+ 0
- 48
example/.flowconfig Vedi File

@@ -1,48 +0,0 @@
1
-[ignore]
2
-; We fork some components by platform
3
-.*/*[.]android.js
4
-
5
-; Ignore "BUCK" generated dirs
6
-<PROJECT_ROOT>/\.buckd/
7
-
8
-; Ignore unexpected extra "@providesModule"
9
-.*/node_modules/.*/node_modules/fbjs/.*
10
-
11
-; Ignore duplicate module providers
12
-; For RN Apps installed via npm, "Libraries" folder is inside
13
-; "node_modules/react-native" but in the source repo it is in the root
14
-.*/Libraries/react-native/React.js
15
-
16
-; Ignore polyfills
17
-.*/Libraries/polyfills/.*
18
-
19
-[include]
20
-
21
-[libs]
22
-node_modules/react-native/Libraries/react-native/react-native-interface.js
23
-node_modules/react-native/flow/
24
-
25
-[options]
26
-emoji=true
27
-
28
-module.system=haste
29
-
30
-munge_underscores=true
31
-
32
-module.name_mapper='^[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\)$' -> 'RelativeImageStub'
33
-
34
-suppress_type=$FlowIssue
35
-suppress_type=$FlowFixMe
36
-suppress_type=$FlowFixMeProps
37
-suppress_type=$FlowFixMeState
38
-suppress_type=$FixMe
39
-
40
-suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(>=0\\.\\(5[0-6]\\|[1-4][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)
41
-suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(>=0\\.\\(5[0-6]\\|[1-4][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+
42
-suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy
43
-suppress_comment=\\(.\\|\n\\)*\\$FlowExpectedError
44
-
45
-unsafe.enable_getters_and_setters=true
46
-
47
-[version]
48
-^0.56.0

+ 0
- 53
example/.gitignore Vedi File

@@ -1,53 +0,0 @@
1
-# OSX
2
-#
3
-.DS_Store
4
-
5
-# Xcode
6
-#
7
-build/
8
-*.pbxuser
9
-!default.pbxuser
10
-*.mode1v3
11
-!default.mode1v3
12
-*.mode2v3
13
-!default.mode2v3
14
-*.perspectivev3
15
-!default.perspectivev3
16
-xcuserdata
17
-*.xccheckout
18
-*.moved-aside
19
-DerivedData
20
-*.hmap
21
-*.ipa
22
-*.xcuserstate
23
-project.xcworkspace
24
-
25
-# Android/IntelliJ
26
-#
27
-build/
28
-.idea
29
-.gradle
30
-local.properties
31
-*.iml
32
-
33
-# node.js
34
-#
35
-node_modules/
36
-npm-debug.log
37
-yarn-error.log
38
-
39
-# BUCK
40
-buck-out/
41
-\.buckd/
42
-*.keystore
43
-
44
-# fastlane
45
-#
46
-# It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the
47
-# screenshots whenever they are needed.
48
-# For more information about the recommended setup visit:
49
-# https://docs.fastlane.tools/best-practices/source-control/
50
-
51
-*/fastlane/report.xml
52
-*/fastlane/Preview.html
53
-*/fastlane/screenshots

+ 0
- 1
example/.watchmanconfig Vedi File

@@ -1 +0,0 @@
1
-{}

+ 34
- 35
example/App.js Vedi File

@@ -1,6 +1,7 @@
1 1
 // @flow
2 2
 
3
-import React, { Component } from 'react'
3
+import React, {Component} from 'react';
4
+
4 5
 import {
5 6
   StyleSheet,
6 7
   TouchableHighlight,
@@ -9,38 +10,38 @@ import {
9 10
   Alert,
10 11
   AppState,
11 12
   Platform,
12
-} from 'react-native'
13
+} from 'react-native';
13 14
 
14
-import Permissions from 'react-native-permissions'
15
+import Permissions from 'react-native-permissions';
15 16
 
16 17
 export default class App extends Component {
17 18
   state = {
18 19
     types: [],
19 20
     status: {},
20
-  }
21
+  };
21 22
 
22 23
   componentDidMount() {
23
-    let types = Permissions.getTypes()
24
-    let canOpenSettings = Permissions.canOpenSettings()
24
+    let types = Permissions.getTypes();
25
+    let canOpenSettings = Permissions.canOpenSettings();
25 26
 
26
-    this.setState({ types, canOpenSettings })
27
-    this._updatePermissions(types)
28
-    AppState.addEventListener('change', this._handleAppStateChange)
27
+    this.setState({types, canOpenSettings});
28
+    this._updatePermissions(types);
29
+    AppState.addEventListener('change', this._handleAppStateChange);
29 30
   }
30 31
 
31 32
   componentWillUnmount() {
32
-    AppState.removeEventListener('change', this._handleAppStateChange)
33
+    AppState.removeEventListener('change', this._handleAppStateChange);
33 34
   }
34 35
 
35 36
   //update permissions when app comes back from settings
36 37
   _handleAppStateChange = appState => {
37 38
     if (appState == 'active') {
38
-      this._updatePermissions(this.state.types)
39
+      this._updatePermissions(this.state.types);
39 40
     }
40
-  }
41
+  };
41 42
 
42 43
   _openSettings = () =>
43
-    Permissions.openSettings().then(() => alert('back to app!!'))
44
+    Permissions.openSettings().then(() => alert('back to app!!'));
44 45
 
45 46
   _updatePermissions = types => {
46 47
     Permissions.checkMultiple(types)
@@ -49,47 +50,47 @@ export default class App extends Component {
49 50
           return Permissions.check('location', 'always').then(location => ({
50 51
             ...status,
51 52
             location,
52
-          }))
53
+          }));
53 54
         }
54
-        return status
55
+        return status;
55 56
       })
56
-      .then(status => this.setState({ status }))
57
-  }
57
+      .then(status => this.setState({status}));
58
+  };
58 59
 
59 60
   _requestPermission = permission => {
60
-    var options
61
+    var options;
61 62
 
62 63
     if (permission == 'location') {
63
-      options = this.state.isAlways ? 'always' : 'whenInUse'
64
+      options = this.state.isAlways ? 'always' : 'whenInUse';
64 65
     }
65 66
 
66 67
     Permissions.request(permission, options)
67 68
       .then(res => {
68 69
         this.setState({
69
-          status: { ...this.state.status, [permission]: res },
70
-        })
70
+          status: {...this.state.status, [permission]: res},
71
+        });
71 72
         if (res != 'authorized') {
72
-          var buttons = [{ text: 'Cancel', style: 'cancel' }]
73
+          var buttons = [{text: 'Cancel', style: 'cancel'}];
73 74
           if (this.state.canOpenSettings)
74 75
             buttons.push({
75 76
               text: 'Open Settings',
76 77
               onPress: this._openSettings,
77
-            })
78
+            });
78 79
 
79 80
           Alert.alert(
80 81
             'Whoops!',
81 82
             'There was a problem getting your permission. Please enable it from settings.',
82 83
             buttons,
83
-          )
84
+          );
84 85
         }
85 86
       })
86
-      .catch(e => console.warn(e))
87
-  }
87
+      .catch(e => console.warn(e));
88
+  };
88 89
 
89 90
   _onLocationSwitchChange = () => {
90
-    this.setState({ isAlways: !this.state.isAlways })
91
-    this._updatePermissions(this.state.types)
92
-  }
91
+    this.setState({isAlways: !this.state.isAlways});
92
+    this._updatePermissions(this.state.types);
93
+  };
93 94
 
94 95
   render() {
95 96
     return (
@@ -98,8 +99,7 @@ export default class App extends Component {
98 99
           <TouchableHighlight
99 100
             style={[styles.button, styles[this.state.status[p]]]}
100 101
             key={p}
101
-            onPress={() => this._requestPermission(p)}
102
-          >
102
+            onPress={() => this._requestPermission(p)}>
103 103
             <View>
104 104
               <Text style={styles.text}>
105 105
                 {Platform.OS == 'ios' && p == 'location'
@@ -113,8 +113,7 @@ export default class App extends Component {
113 113
         <View style={styles.footer}>
114 114
           <TouchableHighlight
115 115
             style={styles['footer_' + Platform.OS]}
116
-            onPress={this._onLocationSwitchChange}
117
-          >
116
+            onPress={this._onLocationSwitchChange}>
118 117
             <Text style={styles.text}>Toggle location type</Text>
119 118
           </TouchableHighlight>
120 119
 
@@ -131,7 +130,7 @@ export default class App extends Component {
131 130
           crash. This is normal on iOS. Google "ios crash permission change"
132 131
         </Text>
133 132
       </View>
134
-    )
133
+    );
135 134
   }
136 135
 }
137 136
 
@@ -179,4 +178,4 @@ const styles = StyleSheet.create({
179 178
     height: 0,
180 179
     width: 0,
181 180
   },
182
-})
181
+});

+ 0
- 10
example/__tests__/index.js Vedi File

@@ -1,10 +0,0 @@
1
-import 'react-native'
2
-import React from 'react'
3
-import Index from '../index.js'
4
-
5
-// Note: test renderer must be required after react-native.
6
-import renderer from 'react-test-renderer'
7
-
8
-it('renders correctly', () => {
9
-  const tree = renderer.create(<Index />)
10
-})

+ 6
- 16
example/android/app/BUCK Vedi File

@@ -8,23 +8,13 @@
8 8
 # - `buck install -r android/app` - compile, install and run application
9 9
 #
10 10
 
11
+load(":build_defs.bzl", "create_aar_targets", "create_jar_targets")
12
+
11 13
 lib_deps = []
12 14
 
13
-for jarfile in glob(['libs/*.jar']):
14
-  name = 'jars__' + jarfile[jarfile.rindex('/') + 1: jarfile.rindex('.jar')]
15
-  lib_deps.append(':' + name)
16
-  prebuilt_jar(
17
-    name = name,
18
-    binary_jar = jarfile,
19
-  )
15
+create_aar_targets(glob(["libs/*.aar"]))
20 16
 
21
-for aarfile in glob(['libs/*.aar']):
22
-  name = 'aars__' + aarfile[aarfile.rindex('/') + 1: aarfile.rindex('.aar')]
23
-  lib_deps.append(':' + name)
24
-  android_prebuilt_aar(
25
-    name = name,
26
-    aar = aarfile,
27
-  )
17
+create_jar_targets(glob(["libs/*.jar"]))
28 18
 
29 19
 android_library(
30 20
     name = "all-libs",
@@ -45,12 +35,12 @@ android_library(
45 35
 
46 36
 android_build_config(
47 37
     name = "build_config",
48
-    package = "com.example",
38
+    package = "com.rnpermissionsexample",
49 39
 )
50 40
 
51 41
 android_resource(
52 42
     name = "res",
53
-    package = "com.example",
43
+    package = "com.rnpermissionsexample",
54 44
     res = "src/main/res",
55 45
 )
56 46
 

+ 75
- 15
example/android/app/build.gradle Vedi File

@@ -18,6 +18,9 @@ import com.android.build.OutputFile
18 18
  *   // the entry file for bundle generation
19 19
  *   entryFile: "index.android.js",
20 20
  *
21
+ *   // https://facebook.github.io/react-native/docs/performance#enable-the-ram-format
22
+ *   bundleCommand: "ram-bundle",
23
+ *
21 24
  *   // whether to bundle JS and assets in debug mode
22 25
  *   bundleInDebug: false,
23 26
  *
@@ -73,7 +76,8 @@ import com.android.build.OutputFile
73 76
  */
74 77
 
75 78
 project.ext.react = [
76
-    entryFile: "index.js"
79
+    entryFile: "index.js",
80
+    enableHermes: false,  // clean and rebuild if changing
77 81
 ]
78 82
 
79 83
 apply from: "../../node_modules/react-native/react.gradle"
@@ -93,30 +97,67 @@ def enableSeparateBuildPerCPUArchitecture = false
93 97
  */
94 98
 def enableProguardInReleaseBuilds = false
95 99
 
100
+/**
101
+ * The preferred build flavor of JavaScriptCore.
102
+ *
103
+ * For example, to use the international variant, you can use:
104
+ * `def jscFlavor = 'org.webkit:android-jsc-intl:+'`
105
+ *
106
+ * The international variant includes ICU i18n library and necessary data
107
+ * allowing to use e.g. `Date.toLocaleString` and `String.localeCompare` that
108
+ * give correct results when using with locales other than en-US.  Note that
109
+ * this variant is about 6MiB larger per architecture than default.
110
+ */
111
+def jscFlavor = 'org.webkit:android-jsc:+'
112
+
113
+/**
114
+ * Whether to enable the Hermes VM.
115
+ *
116
+ * This should be set on project.ext.react and mirrored here.  If it is not set
117
+ * on project.ext.react, JavaScript will not be compiled to Hermes Bytecode
118
+ * and the benefits of using Hermes will therefore be sharply reduced.
119
+ */
120
+def enableHermes = project.ext.react.get("enableHermes", false);
121
+
96 122
 android {
97
-    compileSdkVersion 23
98
-    buildToolsVersion "23.0.1"
123
+    compileSdkVersion rootProject.ext.compileSdkVersion
124
+
125
+    compileOptions {
126
+        sourceCompatibility JavaVersion.VERSION_1_8
127
+        targetCompatibility JavaVersion.VERSION_1_8
128
+    }
99 129
 
100 130
     defaultConfig {
101
-        applicationId "com.example"
102
-        minSdkVersion 16
103
-        targetSdkVersion 23
131
+        applicationId "com.rnpermissionsexample"
132
+        minSdkVersion rootProject.ext.minSdkVersion
133
+        targetSdkVersion rootProject.ext.targetSdkVersion
104 134
         versionCode 1
105 135
         versionName "1.0"
106
-        ndk {
107
-            abiFilters "armeabi-v7a", "x86"
108
-        }
109 136
     }
110 137
     splits {
111 138
         abi {
112 139
             reset()
113 140
             enable enableSeparateBuildPerCPUArchitecture
114 141
             universalApk false  // If true, also generate a universal APK
115
-            include "armeabi-v7a", "x86"
142
+            include "armeabi-v7a", "x86", "arm64-v8a", "x86_64"
143
+        }
144
+    }
145
+    signingConfigs {
146
+        debug {
147
+            storeFile file('debug.keystore')
148
+            storePassword 'android'
149
+            keyAlias 'androiddebugkey'
150
+            keyPassword 'android'
116 151
         }
117 152
     }
118 153
     buildTypes {
154
+        debug {
155
+            signingConfig signingConfigs.debug
156
+        }
119 157
         release {
158
+            // Caution! In production, you need to generate your own keystore file.
159
+            // see https://facebook.github.io/react-native/docs/signed-apk-android.
160
+            signingConfig signingConfigs.debug
120 161
             minifyEnabled enableProguardInReleaseBuilds
121 162
             proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro"
122 163
         }
@@ -125,21 +166,38 @@ android {
125 166
     applicationVariants.all { variant ->
126 167
         variant.outputs.each { output ->
127 168
             // For each separate APK per architecture, set a unique version code as described here:
128
-            // http://tools.android.com/tech-docs/new-build-system/user-guide/apk-splits
129
-            def versionCodes = ["armeabi-v7a":1, "x86":2]
169
+            // https://developer.android.com/studio/build/configure-apk-splits.html
170
+            def versionCodes = ["armeabi-v7a": 1, "x86": 2, "arm64-v8a": 3, "x86_64": 4]
130 171
             def abi = output.getFilter(OutputFile.ABI)
131 172
             if (abi != null) {  // null for the universal-debug, universal-release variants
132 173
                 output.versionCodeOverride =
133 174
                         versionCodes.get(abi) * 1048576 + defaultConfig.versionCode
134 175
             }
176
+
135 177
         }
136 178
     }
179
+
180
+    packagingOptions {
181
+        pickFirst '**/armeabi-v7a/libc++_shared.so'
182
+        pickFirst '**/x86/libc++_shared.so'
183
+        pickFirst '**/arm64-v8a/libc++_shared.so'
184
+        pickFirst '**/x86_64/libc++_shared.so'
185
+        pickFirst '**/x86/libjsc.so'
186
+        pickFirst '**/armeabi-v7a/libjsc.so'
187
+    }
137 188
 }
138 189
 
139 190
 dependencies {
140
-    compile fileTree(dir: "libs", include: ["*.jar"])
141
-    compile "com.android.support:appcompat-v7:23.0.1"
142
-    compile "com.facebook.react:react-native:+"  // From node_modules
191
+    implementation fileTree(dir: "libs", include: ["*.jar"])
192
+    implementation "com.facebook.react:react-native:+"  // From node_modules
193
+
194
+    if (enableHermes) {
195
+      def hermesPath = "../../node_modules/hermesvm/android/";
196
+      debugImplementation files(hermesPath + "hermes-debug.aar")
197
+      releaseImplementation files(hermesPath + "hermes-release.aar")
198
+    } else {
199
+      implementation jscFlavor
200
+    }
143 201
 }
144 202
 
145 203
 // Run this once to be able to run the application with BUCK
@@ -148,3 +206,5 @@ task copyDownloadableDepsToLibs(type: Copy) {
148 206
     from configurations.compile
149 207
     into 'libs'
150 208
 }
209
+
210
+apply from: file("../../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesAppBuildGradle(project)

+ 19
- 0
example/android/app/build_defs.bzl Vedi File

@@ -0,0 +1,19 @@
1
+"""Helper definitions to glob .aar and .jar targets"""
2
+
3
+def create_aar_targets(aarfiles):
4
+    for aarfile in aarfiles:
5
+        name = "aars__" + aarfile[aarfile.rindex("/") + 1:aarfile.rindex(".aar")]
6
+        lib_deps.append(":" + name)
7
+        android_prebuilt_aar(
8
+            name = name,
9
+            aar = aarfile,
10
+        )
11
+
12
+def create_jar_targets(jarfiles):
13
+    for jarfile in jarfiles:
14
+        name = "jars__" + jarfile[jarfile.rindex("/") + 1:jarfile.rindex(".jar")]
15
+        lib_deps.append(":" + name)
16
+        prebuilt_jar(
17
+            name = name,
18
+            binary_jar = jarfile,
19
+        )

+ 0
- 60
example/android/app/proguard-rules.pro Vedi File

@@ -8,63 +8,3 @@
8 8
 #   http://developer.android.com/guide/developing/tools/proguard.html
9 9
 
10 10
 # Add any project specific keep options here:
11
-
12
-# If your project uses WebView with JS, uncomment the following
13
-# and specify the fully qualified class name to the JavaScript interface
14
-# class:
15
-#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
16
-#   public *;
17
-#}
18
-
19
-# Disabling obfuscation is useful if you collect stack traces from production crashes
20
-# (unless you are using a system that supports de-obfuscate the stack traces).
21
--dontobfuscate
22
-
23
-# React Native
24
-
25
-# Keep our interfaces so they can be used by other ProGuard rules.
26
-# See http://sourceforge.net/p/proguard/bugs/466/
27
--keep,allowobfuscation @interface com.facebook.proguard.annotations.DoNotStrip
28
--keep,allowobfuscation @interface com.facebook.proguard.annotations.KeepGettersAndSetters
29
--keep,allowobfuscation @interface com.facebook.common.internal.DoNotStrip
30
-
31
-# Do not strip any method/class that is annotated with @DoNotStrip
32
--keep @com.facebook.proguard.annotations.DoNotStrip class *
33
--keep @com.facebook.common.internal.DoNotStrip class *
34
--keepclassmembers class * {
35
-    @com.facebook.proguard.annotations.DoNotStrip *;
36
-    @com.facebook.common.internal.DoNotStrip *;
37
-}
38
-
39
--keepclassmembers @com.facebook.proguard.annotations.KeepGettersAndSetters class * {
40
-  void set*(***);
41
-  *** get*();
42
-}
43
-
44
--keep class * extends com.facebook.react.bridge.JavaScriptModule { *; }
45
--keep class * extends com.facebook.react.bridge.NativeModule { *; }
46
--keepclassmembers,includedescriptorclasses class * { native <methods>; }
47
--keepclassmembers class *  { @com.facebook.react.uimanager.UIProp <fields>; }
48
--keepclassmembers class *  { @com.facebook.react.uimanager.annotations.ReactProp <methods>; }
49
--keepclassmembers class *  { @com.facebook.react.uimanager.annotations.ReactPropGroup <methods>; }
50
-
51
--dontwarn com.facebook.react.**
52
-
53
-# TextLayoutBuilder uses a non-public Android constructor within StaticLayout.
54
-# See libs/proxy/src/main/java/com/facebook/fbui/textlayoutbuilder/proxy for details.
55
--dontwarn android.text.StaticLayout
56
-
57
-# okhttp
58
-
59
--keepattributes Signature
60
--keepattributes *Annotation*
61
--keep class okhttp3.** { *; }
62
--keep interface okhttp3.** { *; }
63
--dontwarn okhttp3.**
64
-
65
-# okio
66
-
67
--keep class sun.misc.Unsafe { *; }
68
--dontwarn java.nio.file.*
69
--dontwarn org.codehaus.mojo.animal_sniffer.IgnoreJRERequirement
70
--dontwarn okio.**

+ 8
- 0
example/android/app/src/debug/AndroidManifest.xml Vedi File

@@ -0,0 +1,8 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
3
+    xmlns:tools="http://schemas.android.com/tools">
4
+
5
+    <uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW"/>
6
+
7
+    <application android:usesCleartextTraffic="true" tools:targetApi="28" tools:ignore="GoogleAppIndexingWarning" />
8
+</manifest>

+ 4
- 8
example/android/app/src/main/AndroidManifest.xml Vedi File

@@ -1,9 +1,8 @@
1 1
 <manifest xmlns:android="http://schemas.android.com/apk/res/android"
2
-    package="com.example"
3
-    android:versionCode="1"
4
-    android:versionName="1.0">
2
+  package="com.rnpermissionsexample">
5 3
 
6 4
     <uses-permission android:name="android.permission.INTERNET" />
5
+
7 6
     <uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW"/>
8 7
     <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>
9 8
     <uses-permission android:name="android.permission.CAMERA"/>
@@ -16,15 +15,12 @@
16 15
     <uses-permission android:name="android.permission.READ_SMS"/>
17 16
     <uses-permission android:name="android.permission.RECEIVE_SMS"/>
18 17
 
19
-    <uses-sdk
20
-        android:minSdkVersion="16"
21
-        android:targetSdkVersion="23" />
22
-
23 18
     <application
24 19
       android:name=".MainApplication"
25
-      android:allowBackup="false"
26 20
       android:label="@string/app_name"
27 21
       android:icon="@mipmap/ic_launcher"
22
+      android:roundIcon="@mipmap/ic_launcher_round"
23
+      android:allowBackup="false"
28 24
       android:theme="@style/AppTheme">
29 25
       <activity
30 26
         android:name=".MainActivity"

example/android/app/src/main/java/com/example/MainActivity.java → example/android/app/src/main/java/com/rnpermissionsexample/MainActivity.java Vedi File

@@ -1,4 +1,4 @@
1
-package com.example;
1
+package com.rnpermissionsexample;
2 2
 
3 3
 import com.facebook.react.ReactActivity;
4 4
 
@@ -10,6 +10,6 @@ public class MainActivity extends ReactActivity {
10 10
      */
11 11
     @Override
12 12
     protected String getMainComponentName() {
13
-        return "Example";
13
+        return "RNPermissionsExample";
14 14
     }
15 15
 }

example/android/app/src/main/java/com/example/MainApplication.java → example/android/app/src/main/java/com/rnpermissionsexample/MainApplication.java Vedi File

@@ -1,14 +1,16 @@
1
-package com.example;
1
+package com.rnpermissionsexample;
2 2
 
3 3
 import android.app.Application;
4
+import android.util.Log;
4 5
 
6
+import com.facebook.react.PackageList;
7
+import com.facebook.hermes.reactexecutor.HermesExecutorFactory;
8
+import com.facebook.react.bridge.JavaScriptExecutorFactory;
5 9
 import com.facebook.react.ReactApplication;
6 10
 import com.facebook.react.ReactNativeHost;
7 11
 import com.facebook.react.ReactPackage;
8
-import com.facebook.react.shell.MainReactPackage;
9 12
 import com.facebook.soloader.SoLoader;
10 13
 
11
-import java.util.Arrays;
12 14
 import java.util.List;
13 15
 
14 16
 public class MainApplication extends Application implements ReactApplication {
@@ -21,9 +23,11 @@ public class MainApplication extends Application implements ReactApplication {
21 23
 
22 24
     @Override
23 25
     protected List<ReactPackage> getPackages() {
24
-      return Arrays.<ReactPackage>asList(
25
-          new MainReactPackage()
26
-      );
26
+      @SuppressWarnings("UnnecessaryLocalVariable")
27
+      List<ReactPackage> packages = new PackageList(this).getPackages();
28
+      // Packages that cannot be autolinked yet can be added manually here, for example:
29
+      // packages.add(new MyReactNativePackage());
30
+      return packages;
27 31
     }
28 32
 
29 33
     @Override

BIN
example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png Vedi File


BIN
example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png Vedi File


BIN
example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png Vedi File


BIN
example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png Vedi File


BIN
example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png Vedi File


BIN
example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png Vedi File


BIN
example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png Vedi File


BIN
example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png Vedi File


BIN
example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png Vedi File


BIN
example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png Vedi File


+ 1
- 1
example/android/app/src/main/res/values/strings.xml Vedi File

@@ -1,3 +1,3 @@
1 1
 <resources>
2
-    <string name="app_name">Example</string>
2
+    <string name="app_name">RNPermissionsExample</string>
3 3
 </resources>

+ 1
- 0
example/android/app/src/main/res/values/styles.xml Vedi File

@@ -3,6 +3,7 @@
3 3
     <!-- Base application theme. -->
4 4
     <style name="AppTheme" parent="Theme.AppCompat.Light.NoActionBar">
5 5
         <!-- Customize your theme here. -->
6
+        <item name="android:textColor">#000000</item>
6 7
     </style>
7 8
 
8 9
 </resources>

+ 17
- 3
example/android/build.gradle Vedi File

@@ -1,11 +1,19 @@
1 1
 // Top-level build file where you can add configuration options common to all sub-projects/modules.
2 2
 
3 3
 buildscript {
4
+    ext {
5
+        buildToolsVersion = "28.0.3"
6
+        minSdkVersion = 16
7
+        compileSdkVersion = 28
8
+        targetSdkVersion = 28
9
+        supportLibVersion = "28.0.0"
10
+    }
4 11
     repositories {
12
+        google()
5 13
         jcenter()
6 14
     }
7 15
     dependencies {
8
-        classpath 'com.android.tools.build:gradle:2.2.3'
16
+        classpath("com.android.tools.build:gradle:3.4.1")
9 17
 
10 18
         // NOTE: Do not place your application dependencies here; they belong
11 19
         // in the individual module build.gradle files
@@ -15,10 +23,16 @@ buildscript {
15 23
 allprojects {
16 24
     repositories {
17 25
         mavenLocal()
18
-        jcenter()
19 26
         maven {
20 27
             // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
21
-            url "$rootDir/../node_modules/react-native/android"
28
+            url("$rootDir/../node_modules/react-native/android")
29
+        }
30
+        maven {
31
+            // Android JSC is installed from npm
32
+            url("$rootDir/../node_modules/jsc-android/dist")
22 33
         }
34
+
35
+        google()
36
+        jcenter()
23 37
     }
24 38
 }

+ 2
- 1
example/android/gradle.properties Vedi File

@@ -17,4 +17,5 @@
17 17
 # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
18 18
 # org.gradle.parallel=true
19 19
 
20
-android.useDeprecatedNdk=true
20
+android.useAndroidX=true
21
+android.enableJetifier=true

BIN
example/android/gradle/wrapper/gradle-wrapper.jar Vedi File


+ 1
- 1
example/android/gradle/wrapper/gradle-wrapper.properties Vedi File

@@ -1,5 +1,5 @@
1 1
 distributionBase=GRADLE_USER_HOME
2 2
 distributionPath=wrapper/dists
3
+distributionUrl=https\://services.gradle.org/distributions/gradle-5.4.1-all.zip
3 4
 zipStoreBase=GRADLE_USER_HOME
4 5
 zipStorePath=wrapper/dists
5
-distributionUrl=https\://services.gradle.org/distributions/gradle-2.14.1-all.zip

+ 59
- 35
example/android/gradlew Vedi File

@@ -1,4 +1,20 @@
1
-#!/usr/bin/env bash
1
+#!/usr/bin/env sh
2
+
3
+#
4
+# Copyright 2015 the original author or authors.
5
+#
6
+# Licensed under the Apache License, Version 2.0 (the "License");
7
+# you may not use this file except in compliance with the License.
8
+# You may obtain a copy of the License at
9
+#
10
+#      http://www.apache.org/licenses/LICENSE-2.0
11
+#
12
+# Unless required by applicable law or agreed to in writing, software
13
+# distributed under the License is distributed on an "AS IS" BASIS,
14
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
+# See the License for the specific language governing permissions and
16
+# limitations under the License.
17
+#
2 18
 
3 19
 ##############################################################################
4 20
 ##
@@ -6,20 +22,38 @@
6 22
 ##
7 23
 ##############################################################################
8 24
 
9
-# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
10
-DEFAULT_JVM_OPTS=""
25
+# Attempt to set APP_HOME
26
+# Resolve links: $0 may be a link
27
+PRG="$0"
28
+# Need this for relative symlinks.
29
+while [ -h "$PRG" ] ; do
30
+    ls=`ls -ld "$PRG"`
31
+    link=`expr "$ls" : '.*-> \(.*\)$'`
32
+    if expr "$link" : '/.*' > /dev/null; then
33
+        PRG="$link"
34
+    else
35
+        PRG=`dirname "$PRG"`"/$link"
36
+    fi
37
+done
38
+SAVED="`pwd`"
39
+cd "`dirname \"$PRG\"`/" >/dev/null
40
+APP_HOME="`pwd -P`"
41
+cd "$SAVED" >/dev/null
11 42
 
12 43
 APP_NAME="Gradle"
13 44
 APP_BASE_NAME=`basename "$0"`
14 45
 
46
+# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
47
+DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
48
+
15 49
 # Use the maximum available, or set MAX_FD != -1 to use that value.
16 50
 MAX_FD="maximum"
17 51
 
18
-warn ( ) {
52
+warn () {
19 53
     echo "$*"
20 54
 }
21 55
 
22
-die ( ) {
56
+die () {
23 57
     echo
24 58
     echo "$*"
25 59
     echo
@@ -30,6 +64,7 @@ die ( ) {
30 64
 cygwin=false
31 65
 msys=false
32 66
 darwin=false
67
+nonstop=false
33 68
 case "`uname`" in
34 69
   CYGWIN* )
35 70
     cygwin=true
@@ -40,31 +75,11 @@ case "`uname`" in
40 75
   MINGW* )
41 76
     msys=true
42 77
     ;;
78
+  NONSTOP* )
79
+    nonstop=true
80
+    ;;
43 81
 esac
44 82
 
45
-# For Cygwin, ensure paths are in UNIX format before anything is touched.
46
-if $cygwin ; then
47
-    [ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"`
48
-fi
49
-
50
-# Attempt to set APP_HOME
51
-# Resolve links: $0 may be a link
52
-PRG="$0"
53
-# Need this for relative symlinks.
54
-while [ -h "$PRG" ] ; do
55
-    ls=`ls -ld "$PRG"`
56
-    link=`expr "$ls" : '.*-> \(.*\)$'`
57
-    if expr "$link" : '/.*' > /dev/null; then
58
-        PRG="$link"
59
-    else
60
-        PRG=`dirname "$PRG"`"/$link"
61
-    fi
62
-done
63
-SAVED="`pwd`"
64
-cd "`dirname \"$PRG\"`/" >&-
65
-APP_HOME="`pwd -P`"
66
-cd "$SAVED" >&-
67
-
68 83
 CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
69 84
 
70 85
 # Determine the Java command to use to start the JVM.
@@ -90,7 +105,7 @@ location of your Java installation."
90 105
 fi
91 106
 
92 107
 # Increase the maximum file descriptors if we can.
93
-if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then
108
+if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
94 109
     MAX_FD_LIMIT=`ulimit -H -n`
95 110
     if [ $? -eq 0 ] ; then
96 111
         if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
@@ -114,6 +129,7 @@ fi
114 129
 if $cygwin ; then
115 130
     APP_HOME=`cygpath --path --mixed "$APP_HOME"`
116 131
     CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
132
+    JAVACMD=`cygpath --unix "$JAVACMD"`
117 133
 
118 134
     # We build the pattern for arguments to be converted via cygpath
119 135
     ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
@@ -154,11 +170,19 @@ if $cygwin ; then
154 170
     esac
155 171
 fi
156 172
 
157
-# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules
158
-function splitJvmOpts() {
159
-    JVM_OPTS=("$@")
173
+# Escape application args
174
+save () {
175
+    for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
176
+    echo " "
160 177
 }
161
-eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS
162
-JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME"
178
+APP_ARGS=$(save "$@")
179
+
180
+# Collect all arguments for the java command, following the shell quoting and substitution rules
181
+eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
182
+
183
+# by default we should be in the correct project dir, but when run from Finder on Mac, the cwd is wrong
184
+if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then
185
+  cd "$(dirname "$0")"
186
+fi
163 187
 
164
-exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@"
188
+exec "$JAVACMD" "$@"

+ 20
- 10
example/android/gradlew.bat Vedi File

@@ -1,3 +1,19 @@
1
+@rem
2
+@rem Copyright 2015 the original author or authors.
3
+@rem
4
+@rem Licensed under the Apache License, Version 2.0 (the "License");
5
+@rem you may not use this file except in compliance with the License.
6
+@rem You may obtain a copy of the License at
7
+@rem
8
+@rem      http://www.apache.org/licenses/LICENSE-2.0
9
+@rem
10
+@rem Unless required by applicable law or agreed to in writing, software
11
+@rem distributed under the License is distributed on an "AS IS" BASIS,
12
+@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+@rem See the License for the specific language governing permissions and
14
+@rem limitations under the License.
15
+@rem
16
+
1 17
 @if "%DEBUG%" == "" @echo off
2 18
 @rem ##########################################################################
3 19
 @rem
@@ -8,14 +24,14 @@
8 24
 @rem Set local scope for the variables with windows NT shell
9 25
 if "%OS%"=="Windows_NT" setlocal
10 26
 
11
-@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
12
-set DEFAULT_JVM_OPTS=
13
-
14 27
 set DIRNAME=%~dp0
15 28
 if "%DIRNAME%" == "" set DIRNAME=.
16 29
 set APP_BASE_NAME=%~n0
17 30
 set APP_HOME=%DIRNAME%
18 31
 
32
+@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
33
+set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
34
+
19 35
 @rem Find java.exe
20 36
 if defined JAVA_HOME goto findJavaFromJavaHome
21 37
 
@@ -46,10 +62,9 @@ echo location of your Java installation.
46 62
 goto fail
47 63
 
48 64
 :init
49
-@rem Get command-line arguments, handling Windowz variants
65
+@rem Get command-line arguments, handling Windows variants
50 66
 
51 67
 if not "%OS%" == "Windows_NT" goto win9xME_args
52
-if "%@eval[2+2]" == "4" goto 4NT_args
53 68
 
54 69
 :win9xME_args
55 70
 @rem Slurp the command line arguments.
@@ -60,11 +75,6 @@ set _SKIP=2
60 75
 if "x%~1" == "x" goto execute
61 76
 
62 77
 set CMD_LINE_ARGS=%*
63
-goto execute
64
-
65
-:4NT_args
66
-@rem Get arguments from the 4NT Shell from JP Software
67
-set CMD_LINE_ARGS=%$
68 78
 
69 79
 :execute
70 80
 @rem Setup the command line

+ 0
- 8
example/android/keystores/BUCK Vedi File

@@ -1,8 +0,0 @@
1
-keystore(
2
-    name = "debug",
3
-    properties = "debug.keystore.properties",
4
-    store = "debug.keystore",
5
-    visibility = [
6
-        "PUBLIC",
7
-    ],
8
-)

+ 0
- 4
example/android/keystores/debug.keystore.properties Vedi File

@@ -1,4 +0,0 @@
1
-key.store=debug.keystore
2
-key.alias=androiddebugkey
3
-key.store.password=android
4
-key.alias.password=android

+ 2
- 2
example/android/settings.gradle Vedi File

@@ -1,3 +1,3 @@
1
-rootProject.name = 'Example'
2
-
1
+rootProject.name = 'RNPermissionsExample'
2
+apply from: file("../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesSettingsGradle(settings)
3 3
 include ':app'

+ 2
- 2
example/app.json Vedi File

@@ -1,4 +1,4 @@
1 1
 {
2
-  "name": "Example",
3
-  "displayName": "Example"
2
+  "name": "RNPermissionsExample",
3
+  "displayName": "RNPermissionsExample"
4 4
 }

+ 3
- 0
example/babel.config.js Vedi File

@@ -0,0 +1,3 @@
1
+module.exports = {
2
+  presets: ['module:metro-react-native-babel-preset'],
3
+};

+ 8
- 3
example/index.js Vedi File

@@ -1,4 +1,9 @@
1
-import { AppRegistry } from 'react-native'
2
-import App from './App'
1
+/**
2
+ * @format
3
+ */
3 4
 
4
-AppRegistry.registerComponent('Example', () => App)
5
+import {AppRegistry} from 'react-native';
6
+import App from './App';
7
+import {name as appName} from './app.json';
8
+
9
+AppRegistry.registerComponent(appName, () => App);

+ 0
- 24
example/ios/Example-tvOSTests/Info.plist Vedi File

@@ -1,24 +0,0 @@
1
-<?xml version="1.0" encoding="UTF-8"?>
2
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
-<plist version="1.0">
4
-<dict>
5
-	<key>CFBundleDevelopmentRegion</key>
6
-	<string>en</string>
7
-	<key>CFBundleExecutable</key>
8
-	<string>$(EXECUTABLE_NAME)</string>
9
-	<key>CFBundleIdentifier</key>
10
-	<string>org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)</string>
11
-	<key>CFBundleInfoDictionaryVersion</key>
12
-	<string>6.0</string>
13
-	<key>CFBundleName</key>
14
-	<string>$(PRODUCT_NAME)</string>
15
-	<key>CFBundlePackageType</key>
16
-	<string>BNDL</string>
17
-	<key>CFBundleShortVersionString</key>
18
-	<string>1.0</string>
19
-	<key>CFBundleSignature</key>
20
-	<string>????</string>
21
-	<key>CFBundleVersion</key>
22
-	<string>1</string>
23
-</dict>
24
-</plist>

+ 0
- 1525
example/ios/Example.xcodeproj/project.pbxproj
File diff suppressed because it is too large
Vedi File


+ 0
- 129
example/ios/Example.xcodeproj/xcshareddata/xcschemes/Example-tvOS.xcscheme Vedi File

@@ -1,129 +0,0 @@
1
-<?xml version="1.0" encoding="UTF-8"?>
2
-<Scheme
3
-   LastUpgradeVersion = "0820"
4
-   version = "1.3">
5
-   <BuildAction
6
-      parallelizeBuildables = "NO"
7
-      buildImplicitDependencies = "YES">
8
-      <BuildActionEntries>
9
-         <BuildActionEntry
10
-            buildForTesting = "YES"
11
-            buildForRunning = "YES"
12
-            buildForProfiling = "YES"
13
-            buildForArchiving = "YES"
14
-            buildForAnalyzing = "YES">
15
-            <BuildableReference
16
-               BuildableIdentifier = "primary"
17
-               BlueprintIdentifier = "2D2A28121D9B038B00D4039D"
18
-               BuildableName = "libReact.a"
19
-               BlueprintName = "React-tvOS"
20
-               ReferencedContainer = "container:../node_modules/react-native/React/React.xcodeproj">
21
-            </BuildableReference>
22
-         </BuildActionEntry>
23
-         <BuildActionEntry
24
-            buildForTesting = "YES"
25
-            buildForRunning = "YES"
26
-            buildForProfiling = "YES"
27
-            buildForArchiving = "YES"
28
-            buildForAnalyzing = "YES">
29
-            <BuildableReference
30
-               BuildableIdentifier = "primary"
31
-               BlueprintIdentifier = "2D02E47A1E0B4A5D006451C7"
32
-               BuildableName = "Example-tvOS.app"
33
-               BlueprintName = "Example-tvOS"
34
-               ReferencedContainer = "container:Example.xcodeproj">
35
-            </BuildableReference>
36
-         </BuildActionEntry>
37
-         <BuildActionEntry
38
-            buildForTesting = "YES"
39
-            buildForRunning = "YES"
40
-            buildForProfiling = "NO"
41
-            buildForArchiving = "NO"
42
-            buildForAnalyzing = "YES">
43
-            <BuildableReference
44
-               BuildableIdentifier = "primary"
45
-               BlueprintIdentifier = "2D02E48F1E0B4A5D006451C7"
46
-               BuildableName = "Example-tvOSTests.xctest"
47
-               BlueprintName = "Example-tvOSTests"
48
-               ReferencedContainer = "container:Example.xcodeproj">
49
-            </BuildableReference>
50
-         </BuildActionEntry>
51
-      </BuildActionEntries>
52
-   </BuildAction>
53
-   <TestAction
54
-      buildConfiguration = "Debug"
55
-      selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
56
-      selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
57
-      shouldUseLaunchSchemeArgsEnv = "YES">
58
-      <Testables>
59
-         <TestableReference
60
-            skipped = "NO">
61
-            <BuildableReference
62
-               BuildableIdentifier = "primary"
63
-               BlueprintIdentifier = "2D02E48F1E0B4A5D006451C7"
64
-               BuildableName = "Example-tvOSTests.xctest"
65
-               BlueprintName = "Example-tvOSTests"
66
-               ReferencedContainer = "container:Example.xcodeproj">
67
-            </BuildableReference>
68
-         </TestableReference>
69
-      </Testables>
70
-      <MacroExpansion>
71
-         <BuildableReference
72
-            BuildableIdentifier = "primary"
73
-            BlueprintIdentifier = "2D02E47A1E0B4A5D006451C7"
74
-            BuildableName = "Example-tvOS.app"
75
-            BlueprintName = "Example-tvOS"
76
-            ReferencedContainer = "container:Example.xcodeproj">
77
-         </BuildableReference>
78
-      </MacroExpansion>
79
-      <AdditionalOptions>
80
-      </AdditionalOptions>
81
-   </TestAction>
82
-   <LaunchAction
83
-      buildConfiguration = "Debug"
84
-      selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
85
-      selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
86
-      launchStyle = "0"
87
-      useCustomWorkingDirectory = "NO"
88
-      ignoresPersistentStateOnLaunch = "NO"
89
-      debugDocumentVersioning = "YES"
90
-      debugServiceExtension = "internal"
91
-      allowLocationSimulation = "YES">
92
-      <BuildableProductRunnable
93
-         runnableDebuggingMode = "0">
94
-         <BuildableReference
95
-            BuildableIdentifier = "primary"
96
-            BlueprintIdentifier = "2D02E47A1E0B4A5D006451C7"
97
-            BuildableName = "Example-tvOS.app"
98
-            BlueprintName = "Example-tvOS"
99
-            ReferencedContainer = "container:Example.xcodeproj">
100
-         </BuildableReference>
101
-      </BuildableProductRunnable>
102
-      <AdditionalOptions>
103
-      </AdditionalOptions>
104
-   </LaunchAction>
105
-   <ProfileAction
106
-      buildConfiguration = "Release"
107
-      shouldUseLaunchSchemeArgsEnv = "YES"
108
-      savedToolIdentifier = ""
109
-      useCustomWorkingDirectory = "NO"
110
-      debugDocumentVersioning = "YES">
111
-      <BuildableProductRunnable
112
-         runnableDebuggingMode = "0">
113
-         <BuildableReference
114
-            BuildableIdentifier = "primary"
115
-            BlueprintIdentifier = "2D02E47A1E0B4A5D006451C7"
116
-            BuildableName = "Example-tvOS.app"
117
-            BlueprintName = "Example-tvOS"
118
-            ReferencedContainer = "container:Example.xcodeproj">
119
-         </BuildableReference>
120
-      </BuildableProductRunnable>
121
-   </ProfileAction>
122
-   <AnalyzeAction
123
-      buildConfiguration = "Debug">
124
-   </AnalyzeAction>
125
-   <ArchiveAction
126
-      buildConfiguration = "Release"
127
-      revealArchiveInOrganizer = "YES">
128
-   </ArchiveAction>
129
-</Scheme>

+ 0
- 16
example/ios/Example/AppDelegate.h Vedi File

@@ -1,16 +0,0 @@
1
-/**
2
- * Copyright (c) 2015-present, Facebook, Inc.
3
- * All rights reserved.
4
- *
5
- * This source code is licensed under the BSD-style license found in the
6
- * LICENSE file in the root directory of this source tree. An additional grant
7
- * of patent rights can be found in the PATENTS file in the same directory.
8
- */
9
-
10
-#import <UIKit/UIKit.h>
11
-
12
-@interface AppDelegate : UIResponder <UIApplicationDelegate>
13
-
14
-@property (nonatomic, strong) UIWindow *window;
15
-
16
-@end

+ 0
- 37
example/ios/Example/AppDelegate.m Vedi File

@@ -1,37 +0,0 @@
1
-/**
2
- * Copyright (c) 2015-present, Facebook, Inc.
3
- * All rights reserved.
4
- *
5
- * This source code is licensed under the BSD-style license found in the
6
- * LICENSE file in the root directory of this source tree. An additional grant
7
- * of patent rights can be found in the PATENTS file in the same directory.
8
- */
9
-
10
-#import "AppDelegate.h"
11
-
12
-#import <React/RCTBundleURLProvider.h>
13
-#import <React/RCTRootView.h>
14
-
15
-@implementation AppDelegate
16
-
17
-- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
18
-{
19
-  NSURL *jsCodeLocation;
20
-
21
-  jsCodeLocation = [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index" fallbackResource:nil];
22
-
23
-  RCTRootView *rootView = [[RCTRootView alloc] initWithBundleURL:jsCodeLocation
24
-                                                      moduleName:@"Example"
25
-                                               initialProperties:nil
26
-                                                   launchOptions:launchOptions];
27
-  rootView.backgroundColor = [[UIColor alloc] initWithRed:1.0f green:1.0f blue:1.0f alpha:1];
28
-
29
-  self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
30
-  UIViewController *rootViewController = [UIViewController new];
31
-  rootViewController.view = rootView;
32
-  self.window.rootViewController = rootViewController;
33
-  [self.window makeKeyAndVisible];
34
-  return YES;
35
-}
36
-
37
-@end

+ 0
- 83
example/ios/Example/Info.plist Vedi File

@@ -1,83 +0,0 @@
1
-<?xml version="1.0" encoding="UTF-8"?>
2
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
-<plist version="1.0">
4
-<dict>
5
-	<key>CFBundleDevelopmentRegion</key>
6
-	<string>en</string>
7
-	<key>CFBundleDisplayName</key>
8
-	<string>Example</string>
9
-	<key>CFBundleExecutable</key>
10
-	<string>$(EXECUTABLE_NAME)</string>
11
-	<key>CFBundleIdentifier</key>
12
-	<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
13
-	<key>CFBundleInfoDictionaryVersion</key>
14
-	<string>6.0</string>
15
-	<key>CFBundleName</key>
16
-	<string>$(PRODUCT_NAME)</string>
17
-	<key>CFBundlePackageType</key>
18
-	<string>APPL</string>
19
-	<key>CFBundleShortVersionString</key>
20
-	<string>1.0</string>
21
-	<key>CFBundleSignature</key>
22
-	<string>????</string>
23
-	<key>CFBundleVersion</key>
24
-	<string>1</string>
25
-	<key>LSRequiresIPhoneOS</key>
26
-	<true/>
27
-	<key>NSAppTransportSecurity</key>
28
-	<dict>
29
-		<key>NSExceptionDomains</key>
30
-		<dict>
31
-			<key>localhost</key>
32
-			<dict>
33
-				<key>NSExceptionAllowsInsecureHTTPLoads</key>
34
-				<true/>
35
-			</dict>
36
-		</dict>
37
-	</dict>
38
-	<key>NSAppleMusicUsageDescription</key>
39
-	<string>test</string>
40
-	<key>NSBluetoothPeripheralUsageDescription</key>
41
-	<string>test</string>
42
-	<key>NSCalendarsUsageDescription</key>
43
-	<string>test</string>
44
-	<key>NSCameraUsageDescription</key>
45
-	<string>test</string>
46
-	<key>NSContactsUsageDescription</key>
47
-	<string>test</string>
48
-	<key>NSLocationAlwaysUsageDescription</key>
49
-	<string>test</string>
50
-	<key>NSLocationWhenInUseUsageDescription</key>
51
-	<string>test</string>
52
-	<key>NSMicrophoneUsageDescription</key>
53
-	<string>6.0</string>
54
-	<key>NSPhotoLibraryUsageDescription</key>
55
-	<string>test</string>
56
-	<key>NSRemindersUsageDescription</key>
57
-	<string>test</string>
58
-	<key>NSSpeechRecognitionUsageDescription</key>
59
-	<string>test</string>
60
-	<key>NSMotionUsageDescription</key>
61
-	<string>test</string>
62
-	<key>UIBackgroundModes</key>
63
-	<array>
64
-		<string>bluetooth-peripheral</string>
65
-		<string>fetch</string>
66
-		<string>location</string>
67
-	</array>
68
-	<key>UILaunchStoryboardName</key>
69
-	<string>LaunchScreen</string>
70
-	<key>UIRequiredDeviceCapabilities</key>
71
-	<array>
72
-		<string>armv7</string>
73
-	</array>
74
-	<key>UISupportedInterfaceOrientations</key>
75
-	<array>
76
-		<string>UIInterfaceOrientationPortrait</string>
77
-		<string>UIInterfaceOrientationLandscapeLeft</string>
78
-		<string>UIInterfaceOrientationLandscapeRight</string>
79
-	</array>
80
-	<key>UIViewControllerBasedStatusBarAppearance</key>
81
-	<false/>
82
-</dict>
83
-</plist>

+ 0
- 18
example/ios/Example/main.m Vedi File

@@ -1,18 +0,0 @@
1
-/**
2
- * Copyright (c) 2015-present, Facebook, Inc.
3
- * All rights reserved.
4
- *
5
- * This source code is licensed under the BSD-style license found in the
6
- * LICENSE file in the root directory of this source tree. An additional grant
7
- * of patent rights can be found in the PATENTS file in the same directory.
8
- */
9
-
10
-#import <UIKit/UIKit.h>
11
-
12
-#import "AppDelegate.h"
13
-
14
-int main(int argc, char * argv[]) {
15
-  @autoreleasepool {
16
-    return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
17
-  }
18
-}

+ 0
- 70
example/ios/ExampleTests/ExampleTests.m Vedi File

@@ -1,70 +0,0 @@
1
-/**
2
- * Copyright (c) 2015-present, Facebook, Inc.
3
- * All rights reserved.
4
- *
5
- * This source code is licensed under the BSD-style license found in the
6
- * LICENSE file in the root directory of this source tree. An additional grant
7
- * of patent rights can be found in the PATENTS file in the same directory.
8
- */
9
-
10
-#import <UIKit/UIKit.h>
11
-#import <XCTest/XCTest.h>
12
-
13
-#import <React/RCTLog.h>
14
-#import <React/RCTRootView.h>
15
-
16
-#define TIMEOUT_SECONDS 600
17
-#define TEXT_TO_LOOK_FOR @"Welcome to React Native!"
18
-
19
-@interface ExampleTests : XCTestCase
20
-
21
-@end
22
-
23
-@implementation ExampleTests
24
-
25
-- (BOOL)findSubviewInView:(UIView *)view matching:(BOOL(^)(UIView *view))test
26
-{
27
-  if (test(view)) {
28
-    return YES;
29
-  }
30
-  for (UIView *subview in [view subviews]) {
31
-    if ([self findSubviewInView:subview matching:test]) {
32
-      return YES;
33
-    }
34
-  }
35
-  return NO;
36
-}
37
-
38
-- (void)testRendersWelcomeScreen
39
-{
40
-  UIViewController *vc = [[[RCTSharedApplication() delegate] window] rootViewController];
41
-  NSDate *date = [NSDate dateWithTimeIntervalSinceNow:TIMEOUT_SECONDS];
42
-  BOOL foundElement = NO;
43
-
44
-  __block NSString *redboxError = nil;
45
-  RCTSetLogFunction(^(RCTLogLevel level, RCTLogSource source, NSString *fileName, NSNumber *lineNumber, NSString *message) {
46
-    if (level >= RCTLogLevelError) {
47
-      redboxError = message;
48
-    }
49
-  });
50
-
51
-  while ([date timeIntervalSinceNow] > 0 && !foundElement && !redboxError) {
52
-    [[NSRunLoop mainRunLoop] runMode:NSDefaultRunLoopMode beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]];
53
-    [[NSRunLoop mainRunLoop] runMode:NSRunLoopCommonModes beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]];
54
-
55
-    foundElement = [self findSubviewInView:vc.view matching:^BOOL(UIView *view) {
56
-      if ([view.accessibilityLabel isEqualToString:TEXT_TO_LOOK_FOR]) {
57
-        return YES;
58
-      }
59
-      return NO;
60
-    }];
61
-  }
62
-
63
-  RCTSetLogFunction(RCTDefaultLogFunction);
64
-
65
-  XCTAssertNil(redboxError, @"RedBox error: %@", redboxError);
66
-  XCTAssertTrue(foundElement, @"Couldn't find element with text '%@' in %d seconds", TEXT_TO_LOOK_FOR, TIMEOUT_SECONDS);
67
-}
68
-
69
-
70
-@end

+ 0
- 24
example/ios/ExampleTests/Info.plist Vedi File

@@ -1,24 +0,0 @@
1
-<?xml version="1.0" encoding="UTF-8"?>
2
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
-<plist version="1.0">
4
-<dict>
5
-	<key>CFBundleDevelopmentRegion</key>
6
-	<string>en</string>
7
-	<key>CFBundleExecutable</key>
8
-	<string>$(EXECUTABLE_NAME)</string>
9
-	<key>CFBundleIdentifier</key>
10
-	<string>org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)</string>
11
-	<key>CFBundleInfoDictionaryVersion</key>
12
-	<string>6.0</string>
13
-	<key>CFBundleName</key>
14
-	<string>$(PRODUCT_NAME)</string>
15
-	<key>CFBundlePackageType</key>
16
-	<string>BNDL</string>
17
-	<key>CFBundleShortVersionString</key>
18
-	<string>1.0</string>
19
-	<key>CFBundleSignature</key>
20
-	<string>????</string>
21
-	<key>CFBundleVersion</key>
22
-	<string>1</string>
23
-</dict>
24
-</plist>

+ 32
- 0
example/ios/Podfile Vedi File

@@ -0,0 +1,32 @@
1
+platform :ios, '9.0'
2
+
3
+require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules'
4
+
5
+target 'RNPermissionsExample' do
6
+  pod 'React', :path => '../node_modules/react-native/'
7
+  pod 'React-Core', :path => '../node_modules/react-native/React'
8
+  pod 'React-DevSupport', :path => '../node_modules/react-native/React'
9
+  pod 'React-fishhook', :path => '../node_modules/react-native/Libraries/fishhook'
10
+  pod 'React-RCTActionSheet', :path => '../node_modules/react-native/Libraries/ActionSheetIOS'
11
+  pod 'React-RCTAnimation', :path => '../node_modules/react-native/Libraries/NativeAnimation'
12
+  pod 'React-RCTBlob', :path => '../node_modules/react-native/Libraries/Blob'
13
+  pod 'React-RCTImage', :path => '../node_modules/react-native/Libraries/Image'
14
+  pod 'React-RCTLinking', :path => '../node_modules/react-native/Libraries/LinkingIOS'
15
+  pod 'React-RCTNetwork', :path => '../node_modules/react-native/Libraries/Network'
16
+  pod 'React-RCTSettings', :path => '../node_modules/react-native/Libraries/Settings'
17
+  pod 'React-RCTText', :path => '../node_modules/react-native/Libraries/Text'
18
+  pod 'React-RCTVibration', :path => '../node_modules/react-native/Libraries/Vibration'
19
+  pod 'React-RCTWebSocket', :path => '../node_modules/react-native/Libraries/WebSocket'
20
+
21
+  pod 'React-cxxreact', :path => '../node_modules/react-native/ReactCommon/cxxreact'
22
+  pod 'React-jsi', :path => '../node_modules/react-native/ReactCommon/jsi'
23
+  pod 'React-jsiexecutor', :path => '../node_modules/react-native/ReactCommon/jsiexecutor'
24
+  pod 'React-jsinspector', :path => '../node_modules/react-native/ReactCommon/jsinspector'
25
+  pod 'yoga', :path => '../node_modules/react-native/ReactCommon/yoga'
26
+
27
+  pod 'DoubleConversion', :podspec => '../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec'
28
+  pod 'glog', :podspec => '../node_modules/react-native/third-party-podspecs/glog.podspec'
29
+  pod 'Folly', :podspec => '../node_modules/react-native/third-party-podspecs/Folly.podspec'
30
+
31
+  use_native_modules!
32
+end

+ 193
- 0
example/ios/Podfile.lock Vedi File

@@ -0,0 +1,193 @@
1
+PODS:
2
+  - boost-for-react-native (1.63.0)
3
+  - DoubleConversion (1.1.6)
4
+  - Folly (2018.10.22.00):
5
+    - boost-for-react-native
6
+    - DoubleConversion
7
+    - Folly/Default (= 2018.10.22.00)
8
+    - glog
9
+  - Folly/Default (2018.10.22.00):
10
+    - boost-for-react-native
11
+    - DoubleConversion
12
+    - glog
13
+  - glog (0.3.5)
14
+  - React (0.60.3):
15
+    - React-Core (= 0.60.3)
16
+    - React-DevSupport (= 0.60.3)
17
+    - React-RCTActionSheet (= 0.60.3)
18
+    - React-RCTAnimation (= 0.60.3)
19
+    - React-RCTBlob (= 0.60.3)
20
+    - React-RCTImage (= 0.60.3)
21
+    - React-RCTLinking (= 0.60.3)
22
+    - React-RCTNetwork (= 0.60.3)
23
+    - React-RCTSettings (= 0.60.3)
24
+    - React-RCTText (= 0.60.3)
25
+    - React-RCTVibration (= 0.60.3)
26
+    - React-RCTWebSocket (= 0.60.3)
27
+  - React-Core (0.60.3):
28
+    - Folly (= 2018.10.22.00)
29
+    - React-cxxreact (= 0.60.3)
30
+    - React-jsiexecutor (= 0.60.3)
31
+    - yoga (= 0.60.3.React)
32
+  - React-cxxreact (0.60.3):
33
+    - boost-for-react-native (= 1.63.0)
34
+    - DoubleConversion
35
+    - Folly (= 2018.10.22.00)
36
+    - glog
37
+    - React-jsinspector (= 0.60.3)
38
+  - React-DevSupport (0.60.3):
39
+    - React-Core (= 0.60.3)
40
+    - React-RCTWebSocket (= 0.60.3)
41
+  - React-fishhook (0.60.3)
42
+  - React-jsi (0.60.3):
43
+    - boost-for-react-native (= 1.63.0)
44
+    - DoubleConversion
45
+    - Folly (= 2018.10.22.00)
46
+    - glog
47
+    - React-jsi/Default (= 0.60.3)
48
+  - React-jsi/Default (0.60.3):
49
+    - boost-for-react-native (= 1.63.0)
50
+    - DoubleConversion
51
+    - Folly (= 2018.10.22.00)
52
+    - glog
53
+  - React-jsiexecutor (0.60.3):
54
+    - DoubleConversion
55
+    - Folly (= 2018.10.22.00)
56
+    - glog
57
+    - React-cxxreact (= 0.60.3)
58
+    - React-jsi (= 0.60.3)
59
+  - React-jsinspector (0.60.3)
60
+  - React-RCTActionSheet (0.60.3):
61
+    - React-Core (= 0.60.3)
62
+  - React-RCTAnimation (0.60.3):
63
+    - React-Core (= 0.60.3)
64
+  - React-RCTBlob (0.60.3):
65
+    - React-Core (= 0.60.3)
66
+    - React-RCTNetwork (= 0.60.3)
67
+    - React-RCTWebSocket (= 0.60.3)
68
+  - React-RCTImage (0.60.3):
69
+    - React-Core (= 0.60.3)
70
+    - React-RCTNetwork (= 0.60.3)
71
+  - React-RCTLinking (0.60.3):
72
+    - React-Core (= 0.60.3)
73
+  - React-RCTNetwork (0.60.3):
74
+    - React-Core (= 0.60.3)
75
+  - React-RCTSettings (0.60.3):
76
+    - React-Core (= 0.60.3)
77
+  - React-RCTText (0.60.3):
78
+    - React-Core (= 0.60.3)
79
+  - React-RCTVibration (0.60.3):
80
+    - React-Core (= 0.60.3)
81
+  - React-RCTWebSocket (0.60.3):
82
+    - React-Core (= 0.60.3)
83
+    - React-fishhook (= 0.60.3)
84
+  - ReactNativePermissions (1.2.0):
85
+    - React
86
+  - yoga (0.60.3.React)
87
+
88
+DEPENDENCIES:
89
+  - DoubleConversion (from `../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec`)
90
+  - Folly (from `../node_modules/react-native/third-party-podspecs/Folly.podspec`)
91
+  - glog (from `../node_modules/react-native/third-party-podspecs/glog.podspec`)
92
+  - React (from `../node_modules/react-native/`)
93
+  - React-Core (from `../node_modules/react-native/React`)
94
+  - React-cxxreact (from `../node_modules/react-native/ReactCommon/cxxreact`)
95
+  - React-DevSupport (from `../node_modules/react-native/React`)
96
+  - React-fishhook (from `../node_modules/react-native/Libraries/fishhook`)
97
+  - React-jsi (from `../node_modules/react-native/ReactCommon/jsi`)
98
+  - React-jsiexecutor (from `../node_modules/react-native/ReactCommon/jsiexecutor`)
99
+  - React-jsinspector (from `../node_modules/react-native/ReactCommon/jsinspector`)
100
+  - React-RCTActionSheet (from `../node_modules/react-native/Libraries/ActionSheetIOS`)
101
+  - React-RCTAnimation (from `../node_modules/react-native/Libraries/NativeAnimation`)
102
+  - React-RCTBlob (from `../node_modules/react-native/Libraries/Blob`)
103
+  - React-RCTImage (from `../node_modules/react-native/Libraries/Image`)
104
+  - React-RCTLinking (from `../node_modules/react-native/Libraries/LinkingIOS`)
105
+  - React-RCTNetwork (from `../node_modules/react-native/Libraries/Network`)
106
+  - React-RCTSettings (from `../node_modules/react-native/Libraries/Settings`)
107
+  - React-RCTText (from `../node_modules/react-native/Libraries/Text`)
108
+  - React-RCTVibration (from `../node_modules/react-native/Libraries/Vibration`)
109
+  - React-RCTWebSocket (from `../node_modules/react-native/Libraries/WebSocket`)
110
+  - ReactNativePermissions (from `../node_modules/react-native-permissions`)
111
+  - yoga (from `../node_modules/react-native/ReactCommon/yoga`)
112
+
113
+SPEC REPOS:
114
+  https://github.com/cocoapods/specs.git:
115
+    - boost-for-react-native
116
+
117
+EXTERNAL SOURCES:
118
+  DoubleConversion:
119
+    :podspec: "../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec"
120
+  Folly:
121
+    :podspec: "../node_modules/react-native/third-party-podspecs/Folly.podspec"
122
+  glog:
123
+    :podspec: "../node_modules/react-native/third-party-podspecs/glog.podspec"
124
+  React:
125
+    :path: "../node_modules/react-native/"
126
+  React-Core:
127
+    :path: "../node_modules/react-native/React"
128
+  React-cxxreact:
129
+    :path: "../node_modules/react-native/ReactCommon/cxxreact"
130
+  React-DevSupport:
131
+    :path: "../node_modules/react-native/React"
132
+  React-fishhook:
133
+    :path: "../node_modules/react-native/Libraries/fishhook"
134
+  React-jsi:
135
+    :path: "../node_modules/react-native/ReactCommon/jsi"
136
+  React-jsiexecutor:
137
+    :path: "../node_modules/react-native/ReactCommon/jsiexecutor"
138
+  React-jsinspector:
139
+    :path: "../node_modules/react-native/ReactCommon/jsinspector"
140
+  React-RCTActionSheet:
141
+    :path: "../node_modules/react-native/Libraries/ActionSheetIOS"
142
+  React-RCTAnimation:
143
+    :path: "../node_modules/react-native/Libraries/NativeAnimation"
144
+  React-RCTBlob:
145
+    :path: "../node_modules/react-native/Libraries/Blob"
146
+  React-RCTImage:
147
+    :path: "../node_modules/react-native/Libraries/Image"
148
+  React-RCTLinking:
149
+    :path: "../node_modules/react-native/Libraries/LinkingIOS"
150
+  React-RCTNetwork:
151
+    :path: "../node_modules/react-native/Libraries/Network"
152
+  React-RCTSettings:
153
+    :path: "../node_modules/react-native/Libraries/Settings"
154
+  React-RCTText:
155
+    :path: "../node_modules/react-native/Libraries/Text"
156
+  React-RCTVibration:
157
+    :path: "../node_modules/react-native/Libraries/Vibration"
158
+  React-RCTWebSocket:
159
+    :path: "../node_modules/react-native/Libraries/WebSocket"
160
+  ReactNativePermissions:
161
+    :path: "../node_modules/react-native-permissions"
162
+  yoga:
163
+    :path: "../node_modules/react-native/ReactCommon/yoga"
164
+
165
+SPEC CHECKSUMS:
166
+  boost-for-react-native: 39c7adb57c4e60d6c5479dd8623128eb5b3f0f2c
167
+  DoubleConversion: 5805e889d232975c086db112ece9ed034df7a0b2
168
+  Folly: 30e7936e1c45c08d884aa59369ed951a8e68cf51
169
+  glog: 1f3da668190260b06b429bb211bfbee5cd790c28
170
+  React: ac23e9cc8d2d4cfe9b536b5cc0c32d19b9937bcf
171
+  React-Core: 84de3cf80e31f0267c5ce0b5b482d59ce30a8a57
172
+  React-cxxreact: a802a1c6b14f3de66ba032460b424c17ececd1e2
173
+  React-DevSupport: ae72c4fc86c03197f007bb24404077c85f6dabc1
174
+  React-fishhook: 12bd79b4461280f441937dea83f11d9fb660edfc
175
+  React-jsi: c2b6e57836bcae2677a036384111dc2c58e94369
176
+  React-jsiexecutor: d9023c5c199114d2b6f38ec861a4d923c73d0735
177
+  React-jsinspector: 817b64f3c8a807f09d78620f4f505868d89b26f3
178
+  React-RCTActionSheet: 9c42321fd5652515d706dd722c5a10b1970d7ec8
179
+  React-RCTAnimation: fabb087dde8964c9a835a7fabd0e7e5701787913
180
+  React-RCTBlob: 93f34281d9c9c9e216b25824309eed9fe22a5d41
181
+  React-RCTImage: b09f30159b048eb9a0f859f8f9b0878f3311e8eb
182
+  React-RCTLinking: 9dba672b3d5aadab59e93f9ab8c65e5e24b9fb73
183
+  React-RCTNetwork: 4b2f706819f08b6fa15c47909985f96b80859832
184
+  React-RCTSettings: 59c0eedc36b9aa9dd21cdbb5ab9591ba04132b1f
185
+  React-RCTText: b026f8350c2cbe0daeb9880dd9c6e018fce0daf7
186
+  React-RCTVibration: 5d9ed4a968e9d42880ddcc7c29bee3417c745408
187
+  React-RCTWebSocket: 69d8565d66043f244b4129f3d7154c5689fb7d3e
188
+  ReactNativePermissions: f3beb8871251594a8ea2c6b19a3f8252d5c7379d
189
+  yoga: 843fe25849b56131275bf3e5da2c468e96f68aff
190
+
191
+PODFILE CHECKSUM: b88bd82c6997520c7ee360ccba0e3d9b29702a06
192
+
193
+COCOAPODS: 1.7.4

+ 405
- 0
example/ios/RNPermissionsExample.xcodeproj/project.pbxproj Vedi File

@@ -0,0 +1,405 @@
1
+// !$*UTF8*$!
2
+{
3
+	archiveVersion = 1;
4
+	classes = {
5
+	};
6
+	objectVersion = 46;
7
+	objects = {
8
+
9
+/* Begin PBXBuildFile section */
10
+		0E06F1D88D53CACFEA8805DA /* libPods-RNPermissionsExample.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 556DF35B5F5B569EF245DD1D /* libPods-RNPermissionsExample.a */; };
11
+		13B07FBC1A68108700A75B9A /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.m */; };
12
+		13B07FBD1A68108700A75B9A /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB11A68108700A75B9A /* LaunchScreen.xib */; };
13
+		13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; };
14
+		13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; };
15
+/* End PBXBuildFile section */
16
+
17
+/* Begin PBXFileReference section */
18
+		008F07F21AC5B25A0029DE68 /* main.jsbundle */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = main.jsbundle; sourceTree = "<group>"; };
19
+		13B07F961A680F5B00A75B9A /* RNPermissionsExample.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = RNPermissionsExample.app; sourceTree = BUILT_PRODUCTS_DIR; };
20
+		13B07FAF1A68108700A75B9A /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = RNPermissionsExample/AppDelegate.h; sourceTree = "<group>"; };
21
+		13B07FB01A68108700A75B9A /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = AppDelegate.m; path = RNPermissionsExample/AppDelegate.m; sourceTree = "<group>"; };
22
+		13B07FB21A68108700A75B9A /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/LaunchScreen.xib; sourceTree = "<group>"; };
23
+		13B07FB51A68108700A75B9A /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = RNPermissionsExample/Images.xcassets; sourceTree = "<group>"; };
24
+		13B07FB61A68108700A75B9A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = RNPermissionsExample/Info.plist; sourceTree = "<group>"; };
25
+		13B07FB71A68108700A75B9A /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = RNPermissionsExample/main.m; sourceTree = "<group>"; };
26
+		41CC55DE2BF4A1CA71460AE5 /* Pods-RNPermissionsExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RNPermissionsExample.release.xcconfig"; path = "Target Support Files/Pods-RNPermissionsExample/Pods-RNPermissionsExample.release.xcconfig"; sourceTree = "<group>"; };
27
+		556DF35B5F5B569EF245DD1D /* libPods-RNPermissionsExample.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-RNPermissionsExample.a"; sourceTree = BUILT_PRODUCTS_DIR; };
28
+		D08F1080D9CA57BA7DA73993 /* Pods-RNPermissionsExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RNPermissionsExample.debug.xcconfig"; path = "Target Support Files/Pods-RNPermissionsExample/Pods-RNPermissionsExample.debug.xcconfig"; sourceTree = "<group>"; };
29
+		ED297162215061F000B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; };
30
+/* End PBXFileReference section */
31
+
32
+/* Begin PBXFrameworksBuildPhase section */
33
+		13B07F8C1A680F5B00A75B9A /* Frameworks */ = {
34
+			isa = PBXFrameworksBuildPhase;
35
+			buildActionMask = 2147483647;
36
+			files = (
37
+				0E06F1D88D53CACFEA8805DA /* libPods-RNPermissionsExample.a in Frameworks */,
38
+			);
39
+			runOnlyForDeploymentPostprocessing = 0;
40
+		};
41
+/* End PBXFrameworksBuildPhase section */
42
+
43
+/* Begin PBXGroup section */
44
+		13B07FAE1A68108700A75B9A /* RNPermissionsExample */ = {
45
+			isa = PBXGroup;
46
+			children = (
47
+				008F07F21AC5B25A0029DE68 /* main.jsbundle */,
48
+				13B07FAF1A68108700A75B9A /* AppDelegate.h */,
49
+				13B07FB01A68108700A75B9A /* AppDelegate.m */,
50
+				13B07FB51A68108700A75B9A /* Images.xcassets */,
51
+				13B07FB61A68108700A75B9A /* Info.plist */,
52
+				13B07FB11A68108700A75B9A /* LaunchScreen.xib */,
53
+				13B07FB71A68108700A75B9A /* main.m */,
54
+			);
55
+			name = RNPermissionsExample;
56
+			sourceTree = "<group>";
57
+		};
58
+		2D16E6871FA4F8E400B85C8A /* Frameworks */ = {
59
+			isa = PBXGroup;
60
+			children = (
61
+				ED297162215061F000B7C4FE /* JavaScriptCore.framework */,
62
+				556DF35B5F5B569EF245DD1D /* libPods-RNPermissionsExample.a */,
63
+			);
64
+			name = Frameworks;
65
+			sourceTree = "<group>";
66
+		};
67
+		83CBB9F61A601CBA00E9B192 = {
68
+			isa = PBXGroup;
69
+			children = (
70
+				13B07FAE1A68108700A75B9A /* RNPermissionsExample */,
71
+				83CBBA001A601CBA00E9B192 /* Products */,
72
+				2D16E6871FA4F8E400B85C8A /* Frameworks */,
73
+				AAD69C6C4FF2C8FD1E65015F /* Pods */,
74
+			);
75
+			indentWidth = 2;
76
+			sourceTree = "<group>";
77
+			tabWidth = 2;
78
+			usesTabs = 0;
79
+		};
80
+		83CBBA001A601CBA00E9B192 /* Products */ = {
81
+			isa = PBXGroup;
82
+			children = (
83
+				13B07F961A680F5B00A75B9A /* RNPermissionsExample.app */,
84
+			);
85
+			name = Products;
86
+			sourceTree = "<group>";
87
+		};
88
+		AAD69C6C4FF2C8FD1E65015F /* Pods */ = {
89
+			isa = PBXGroup;
90
+			children = (
91
+				D08F1080D9CA57BA7DA73993 /* Pods-RNPermissionsExample.debug.xcconfig */,
92
+				41CC55DE2BF4A1CA71460AE5 /* Pods-RNPermissionsExample.release.xcconfig */,
93
+			);
94
+			path = Pods;
95
+			sourceTree = "<group>";
96
+		};
97
+/* End PBXGroup section */
98
+
99
+/* Begin PBXNativeTarget section */
100
+		13B07F861A680F5B00A75B9A /* RNPermissionsExample */ = {
101
+			isa = PBXNativeTarget;
102
+			buildConfigurationList = 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "RNPermissionsExample" */;
103
+			buildPhases = (
104
+				BD4E7135453738F218DAFD9A /* [CP] Check Pods Manifest.lock */,
105
+				FD10A7F022414F080027D42C /* Start Packager */,
106
+				13B07F871A680F5B00A75B9A /* Sources */,
107
+				13B07F8C1A680F5B00A75B9A /* Frameworks */,
108
+				13B07F8E1A680F5B00A75B9A /* Resources */,
109
+				00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */,
110
+			);
111
+			buildRules = (
112
+			);
113
+			dependencies = (
114
+			);
115
+			name = RNPermissionsExample;
116
+			productName = RNPermissionsExample;
117
+			productReference = 13B07F961A680F5B00A75B9A /* RNPermissionsExample.app */;
118
+			productType = "com.apple.product-type.application";
119
+		};
120
+/* End PBXNativeTarget section */
121
+
122
+/* Begin PBXProject section */
123
+		83CBB9F71A601CBA00E9B192 /* Project object */ = {
124
+			isa = PBXProject;
125
+			attributes = {
126
+				LastUpgradeCheck = 0940;
127
+				ORGANIZATIONNAME = Facebook;
128
+			};
129
+			buildConfigurationList = 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "RNPermissionsExample" */;
130
+			compatibilityVersion = "Xcode 3.2";
131
+			developmentRegion = English;
132
+			hasScannedForEncodings = 0;
133
+			knownRegions = (
134
+				English,
135
+				en,
136
+				Base,
137
+			);
138
+			mainGroup = 83CBB9F61A601CBA00E9B192;
139
+			productRefGroup = 83CBBA001A601CBA00E9B192 /* Products */;
140
+			projectDirPath = "";
141
+			projectRoot = "";
142
+			targets = (
143
+				13B07F861A680F5B00A75B9A /* RNPermissionsExample */,
144
+			);
145
+		};
146
+/* End PBXProject section */
147
+
148
+/* Begin PBXResourcesBuildPhase section */
149
+		13B07F8E1A680F5B00A75B9A /* Resources */ = {
150
+			isa = PBXResourcesBuildPhase;
151
+			buildActionMask = 2147483647;
152
+			files = (
153
+				13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */,
154
+				13B07FBD1A68108700A75B9A /* LaunchScreen.xib in Resources */,
155
+			);
156
+			runOnlyForDeploymentPostprocessing = 0;
157
+		};
158
+/* End PBXResourcesBuildPhase section */
159
+
160
+/* Begin PBXShellScriptBuildPhase section */
161
+		00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */ = {
162
+			isa = PBXShellScriptBuildPhase;
163
+			buildActionMask = 2147483647;
164
+			files = (
165
+			);
166
+			inputPaths = (
167
+			);
168
+			name = "Bundle React Native code and images";
169
+			outputPaths = (
170
+			);
171
+			runOnlyForDeploymentPostprocessing = 0;
172
+			shellPath = /bin/sh;
173
+			shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh";
174
+		};
175
+		BD4E7135453738F218DAFD9A /* [CP] Check Pods Manifest.lock */ = {
176
+			isa = PBXShellScriptBuildPhase;
177
+			buildActionMask = 2147483647;
178
+			files = (
179
+			);
180
+			inputFileListPaths = (
181
+			);
182
+			inputPaths = (
183
+				"${PODS_PODFILE_DIR_PATH}/Podfile.lock",
184
+				"${PODS_ROOT}/Manifest.lock",
185
+			);
186
+			name = "[CP] Check Pods Manifest.lock";
187
+			outputFileListPaths = (
188
+			);
189
+			outputPaths = (
190
+				"$(DERIVED_FILE_DIR)/Pods-RNPermissionsExample-checkManifestLockResult.txt",
191
+			);
192
+			runOnlyForDeploymentPostprocessing = 0;
193
+			shellPath = /bin/sh;
194
+			shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n    # print error to STDERR\n    echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n    exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
195
+			showEnvVarsInLog = 0;
196
+		};
197
+		FD10A7F022414F080027D42C /* Start Packager */ = {
198
+			isa = PBXShellScriptBuildPhase;
199
+			buildActionMask = 2147483647;
200
+			files = (
201
+			);
202
+			inputFileListPaths = (
203
+			);
204
+			inputPaths = (
205
+			);
206
+			name = "Start Packager";
207
+			outputFileListPaths = (
208
+			);
209
+			outputPaths = (
210
+			);
211
+			runOnlyForDeploymentPostprocessing = 0;
212
+			shellPath = /bin/sh;
213
+			shellScript = "export RCT_METRO_PORT=\"${RCT_METRO_PORT:=8081}\"\necho \"export RCT_METRO_PORT=${RCT_METRO_PORT}\" > \"${SRCROOT}/../node_modules/react-native/scripts/.packager.env\"\nif [ -z \"${RCT_NO_LAUNCH_PACKAGER+xxx}\" ] ; then\n  if nc -w 5 -z localhost ${RCT_METRO_PORT} ; then\n    if ! curl -s \"http://localhost:${RCT_METRO_PORT}/status\" | grep -q \"packager-status:running\" ; then\n      echo \"Port ${RCT_METRO_PORT} already in use, packager is either not running or not running correctly\"\n      exit 2\n    fi\n  else\n    open \"$SRCROOT/../node_modules/react-native/scripts/launchPackager.command\" || echo \"Can't start packager automatically\"\n  fi\nfi\n";
214
+			showEnvVarsInLog = 0;
215
+		};
216
+/* End PBXShellScriptBuildPhase section */
217
+
218
+/* Begin PBXSourcesBuildPhase section */
219
+		13B07F871A680F5B00A75B9A /* Sources */ = {
220
+			isa = PBXSourcesBuildPhase;
221
+			buildActionMask = 2147483647;
222
+			files = (
223
+				13B07FBC1A68108700A75B9A /* AppDelegate.m in Sources */,
224
+				13B07FC11A68108700A75B9A /* main.m in Sources */,
225
+			);
226
+			runOnlyForDeploymentPostprocessing = 0;
227
+		};
228
+/* End PBXSourcesBuildPhase section */
229
+
230
+/* Begin PBXVariantGroup section */
231
+		13B07FB11A68108700A75B9A /* LaunchScreen.xib */ = {
232
+			isa = PBXVariantGroup;
233
+			children = (
234
+				13B07FB21A68108700A75B9A /* Base */,
235
+			);
236
+			name = LaunchScreen.xib;
237
+			path = RNPermissionsExample;
238
+			sourceTree = "<group>";
239
+		};
240
+/* End PBXVariantGroup section */
241
+
242
+/* Begin XCBuildConfiguration section */
243
+		13B07F941A680F5B00A75B9A /* Debug */ = {
244
+			isa = XCBuildConfiguration;
245
+			baseConfigurationReference = D08F1080D9CA57BA7DA73993 /* Pods-RNPermissionsExample.debug.xcconfig */;
246
+			buildSettings = {
247
+				ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
248
+				CURRENT_PROJECT_VERSION = 1;
249
+				DEAD_CODE_STRIPPING = NO;
250
+				INFOPLIST_FILE = RNPermissionsExample/Info.plist;
251
+				LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
252
+				OTHER_LDFLAGS = (
253
+					"$(inherited)",
254
+					"-ObjC",
255
+					"-lc++",
256
+				);
257
+				PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)";
258
+				PRODUCT_NAME = RNPermissionsExample;
259
+				VERSIONING_SYSTEM = "apple-generic";
260
+			};
261
+			name = Debug;
262
+		};
263
+		13B07F951A680F5B00A75B9A /* Release */ = {
264
+			isa = XCBuildConfiguration;
265
+			baseConfigurationReference = 41CC55DE2BF4A1CA71460AE5 /* Pods-RNPermissionsExample.release.xcconfig */;
266
+			buildSettings = {
267
+				ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
268
+				CURRENT_PROJECT_VERSION = 1;
269
+				INFOPLIST_FILE = RNPermissionsExample/Info.plist;
270
+				LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
271
+				OTHER_LDFLAGS = (
272
+					"$(inherited)",
273
+					"-ObjC",
274
+					"-lc++",
275
+				);
276
+				PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)";
277
+				PRODUCT_NAME = RNPermissionsExample;
278
+				VERSIONING_SYSTEM = "apple-generic";
279
+			};
280
+			name = Release;
281
+		};
282
+		83CBBA201A601CBA00E9B192 /* Debug */ = {
283
+			isa = XCBuildConfiguration;
284
+			buildSettings = {
285
+				ALWAYS_SEARCH_USER_PATHS = NO;
286
+				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
287
+				CLANG_CXX_LIBRARY = "libc++";
288
+				CLANG_ENABLE_MODULES = YES;
289
+				CLANG_ENABLE_OBJC_ARC = YES;
290
+				CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
291
+				CLANG_WARN_BOOL_CONVERSION = YES;
292
+				CLANG_WARN_COMMA = YES;
293
+				CLANG_WARN_CONSTANT_CONVERSION = YES;
294
+				CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
295
+				CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
296
+				CLANG_WARN_EMPTY_BODY = YES;
297
+				CLANG_WARN_ENUM_CONVERSION = YES;
298
+				CLANG_WARN_INFINITE_RECURSION = YES;
299
+				CLANG_WARN_INT_CONVERSION = YES;
300
+				CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
301
+				CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
302
+				CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
303
+				CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
304
+				CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
305
+				CLANG_WARN_STRICT_PROTOTYPES = YES;
306
+				CLANG_WARN_SUSPICIOUS_MOVE = YES;
307
+				CLANG_WARN_UNREACHABLE_CODE = YES;
308
+				CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
309
+				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
310
+				COPY_PHASE_STRIP = NO;
311
+				ENABLE_STRICT_OBJC_MSGSEND = YES;
312
+				ENABLE_TESTABILITY = YES;
313
+				GCC_C_LANGUAGE_STANDARD = gnu99;
314
+				GCC_DYNAMIC_NO_PIC = NO;
315
+				GCC_NO_COMMON_BLOCKS = YES;
316
+				GCC_OPTIMIZATION_LEVEL = 0;
317
+				GCC_PREPROCESSOR_DEFINITIONS = (
318
+					"DEBUG=1",
319
+					"$(inherited)",
320
+				);
321
+				GCC_SYMBOLS_PRIVATE_EXTERN = NO;
322
+				GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
323
+				GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
324
+				GCC_WARN_UNDECLARED_SELECTOR = YES;
325
+				GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
326
+				GCC_WARN_UNUSED_FUNCTION = YES;
327
+				GCC_WARN_UNUSED_VARIABLE = YES;
328
+				IPHONEOS_DEPLOYMENT_TARGET = 9.0;
329
+				MTL_ENABLE_DEBUG_INFO = YES;
330
+				ONLY_ACTIVE_ARCH = YES;
331
+				SDKROOT = iphoneos;
332
+			};
333
+			name = Debug;
334
+		};
335
+		83CBBA211A601CBA00E9B192 /* Release */ = {
336
+			isa = XCBuildConfiguration;
337
+			buildSettings = {
338
+				ALWAYS_SEARCH_USER_PATHS = NO;
339
+				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
340
+				CLANG_CXX_LIBRARY = "libc++";
341
+				CLANG_ENABLE_MODULES = YES;
342
+				CLANG_ENABLE_OBJC_ARC = YES;
343
+				CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
344
+				CLANG_WARN_BOOL_CONVERSION = YES;
345
+				CLANG_WARN_COMMA = YES;
346
+				CLANG_WARN_CONSTANT_CONVERSION = YES;
347
+				CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
348
+				CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
349
+				CLANG_WARN_EMPTY_BODY = YES;
350
+				CLANG_WARN_ENUM_CONVERSION = YES;
351
+				CLANG_WARN_INFINITE_RECURSION = YES;
352
+				CLANG_WARN_INT_CONVERSION = YES;
353
+				CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
354
+				CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
355
+				CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
356
+				CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
357
+				CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
358
+				CLANG_WARN_STRICT_PROTOTYPES = YES;
359
+				CLANG_WARN_SUSPICIOUS_MOVE = YES;
360
+				CLANG_WARN_UNREACHABLE_CODE = YES;
361
+				CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
362
+				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
363
+				COPY_PHASE_STRIP = YES;
364
+				ENABLE_NS_ASSERTIONS = NO;
365
+				ENABLE_STRICT_OBJC_MSGSEND = YES;
366
+				GCC_C_LANGUAGE_STANDARD = gnu99;
367
+				GCC_NO_COMMON_BLOCKS = YES;
368
+				GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
369
+				GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
370
+				GCC_WARN_UNDECLARED_SELECTOR = YES;
371
+				GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
372
+				GCC_WARN_UNUSED_FUNCTION = YES;
373
+				GCC_WARN_UNUSED_VARIABLE = YES;
374
+				IPHONEOS_DEPLOYMENT_TARGET = 9.0;
375
+				MTL_ENABLE_DEBUG_INFO = NO;
376
+				SDKROOT = iphoneos;
377
+				VALIDATE_PRODUCT = YES;
378
+			};
379
+			name = Release;
380
+		};
381
+/* End XCBuildConfiguration section */
382
+
383
+/* Begin XCConfigurationList section */
384
+		13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "RNPermissionsExample" */ = {
385
+			isa = XCConfigurationList;
386
+			buildConfigurations = (
387
+				13B07F941A680F5B00A75B9A /* Debug */,
388
+				13B07F951A680F5B00A75B9A /* Release */,
389
+			);
390
+			defaultConfigurationIsVisible = 0;
391
+			defaultConfigurationName = Release;
392
+		};
393
+		83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "RNPermissionsExample" */ = {
394
+			isa = XCConfigurationList;
395
+			buildConfigurations = (
396
+				83CBBA201A601CBA00E9B192 /* Debug */,
397
+				83CBBA211A601CBA00E9B192 /* Release */,
398
+			);
399
+			defaultConfigurationIsVisible = 0;
400
+			defaultConfigurationName = Release;
401
+		};
402
+/* End XCConfigurationList section */
403
+	};
404
+	rootObject = 83CBB9F71A601CBA00E9B192 /* Project object */;
405
+}

example/ios/Example.xcodeproj/xcshareddata/xcschemes/Example.xcscheme → example/ios/RNPermissionsExample.xcodeproj/xcshareddata/xcschemes/RNPermissionsExample.xcscheme Vedi File

@@ -1,6 +1,6 @@
1 1
 <?xml version="1.0" encoding="UTF-8"?>
2 2
 <Scheme
3
-   LastUpgradeVersion = "0620"
3
+   LastUpgradeVersion = "0940"
4 4
    version = "1.3">
5 5
    <BuildAction
6 6
       parallelizeBuildables = "NO"
@@ -29,9 +29,9 @@
29 29
             <BuildableReference
30 30
                BuildableIdentifier = "primary"
31 31
                BlueprintIdentifier = "13B07F861A680F5B00A75B9A"
32
-               BuildableName = "Example.app"
33
-               BlueprintName = "Example"
34
-               ReferencedContainer = "container:Example.xcodeproj">
32
+               BuildableName = "RNPermissionsExample.app"
33
+               BlueprintName = "RNPermissionsExample"
34
+               ReferencedContainer = "container:RNPermissionsExample.xcodeproj">
35 35
             </BuildableReference>
36 36
          </BuildActionEntry>
37 37
          <BuildActionEntry
@@ -43,9 +43,9 @@
43 43
             <BuildableReference
44 44
                BuildableIdentifier = "primary"
45 45
                BlueprintIdentifier = "00E356ED1AD99517003FC87E"
46
-               BuildableName = "ExampleTests.xctest"
47
-               BlueprintName = "ExampleTests"
48
-               ReferencedContainer = "container:Example.xcodeproj">
46
+               BuildableName = "RNPermissionsExampleTests.xctest"
47
+               BlueprintName = "RNPermissionsExampleTests"
48
+               ReferencedContainer = "container:RNPermissionsExample.xcodeproj">
49 49
             </BuildableReference>
50 50
          </BuildActionEntry>
51 51
       </BuildActionEntries>
@@ -61,9 +61,9 @@
61 61
             <BuildableReference
62 62
                BuildableIdentifier = "primary"
63 63
                BlueprintIdentifier = "00E356ED1AD99517003FC87E"
64
-               BuildableName = "ExampleTests.xctest"
65
-               BlueprintName = "ExampleTests"
66
-               ReferencedContainer = "container:Example.xcodeproj">
64
+               BuildableName = "RNPermissionsExampleTests.xctest"
65
+               BlueprintName = "RNPermissionsExampleTests"
66
+               ReferencedContainer = "container:RNPermissionsExample.xcodeproj">
67 67
             </BuildableReference>
68 68
          </TestableReference>
69 69
       </Testables>
@@ -71,9 +71,9 @@
71 71
          <BuildableReference
72 72
             BuildableIdentifier = "primary"
73 73
             BlueprintIdentifier = "13B07F861A680F5B00A75B9A"
74
-            BuildableName = "Example.app"
75
-            BlueprintName = "Example"
76
-            ReferencedContainer = "container:Example.xcodeproj">
74
+            BuildableName = "RNPermissionsExample.app"
75
+            BlueprintName = "RNPermissionsExample"
76
+            ReferencedContainer = "container:RNPermissionsExample.xcodeproj">
77 77
          </BuildableReference>
78 78
       </MacroExpansion>
79 79
       <AdditionalOptions>
@@ -94,9 +94,9 @@
94 94
          <BuildableReference
95 95
             BuildableIdentifier = "primary"
96 96
             BlueprintIdentifier = "13B07F861A680F5B00A75B9A"
97
-            BuildableName = "Example.app"
98
-            BlueprintName = "Example"
99
-            ReferencedContainer = "container:Example.xcodeproj">
97
+            BuildableName = "RNPermissionsExample.app"
98
+            BlueprintName = "RNPermissionsExample"
99
+            ReferencedContainer = "container:RNPermissionsExample.xcodeproj">
100 100
          </BuildableReference>
101 101
       </BuildableProductRunnable>
102 102
       <AdditionalOptions>
@@ -113,9 +113,9 @@
113 113
          <BuildableReference
114 114
             BuildableIdentifier = "primary"
115 115
             BlueprintIdentifier = "13B07F861A680F5B00A75B9A"
116
-            BuildableName = "Example.app"
117
-            BlueprintName = "Example"
118
-            ReferencedContainer = "container:Example.xcodeproj">
116
+            BuildableName = "RNPermissionsExample.app"
117
+            BlueprintName = "RNPermissionsExample"
118
+            ReferencedContainer = "container:RNPermissionsExample.xcodeproj">
119 119
          </BuildableReference>
120 120
       </BuildableProductRunnable>
121 121
    </ProfileAction>

+ 10
- 0
example/ios/RNPermissionsExample.xcworkspace/contents.xcworkspacedata Vedi File

@@ -0,0 +1,10 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<Workspace
3
+   version = "1.0">
4
+   <FileRef
5
+      location = "group:RNPermissionsExample.xcodeproj">
6
+   </FileRef>
7
+   <FileRef
8
+      location = "group:Pods/Pods.xcodeproj">
9
+   </FileRef>
10
+</Workspace>

+ 8
- 0
example/ios/RNPermissionsExample.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist Vedi File

@@ -0,0 +1,8 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
+<plist version="1.0">
4
+<dict>
5
+	<key>IDEDidComputeMac32BitWarning</key>
6
+	<true/>
7
+</dict>
8
+</plist>

+ 15
- 0
example/ios/RNPermissionsExample/AppDelegate.h Vedi File

@@ -0,0 +1,15 @@
1
+/**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+
8
+#import <React/RCTBridgeDelegate.h>
9
+#import <UIKit/UIKit.h>
10
+
11
+@interface AppDelegate : UIResponder <UIApplicationDelegate, RCTBridgeDelegate>
12
+
13
+@property (nonatomic, strong) UIWindow *window;
14
+
15
+@end

+ 42
- 0
example/ios/RNPermissionsExample/AppDelegate.m Vedi File

@@ -0,0 +1,42 @@
1
+/**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+
8
+#import "AppDelegate.h"
9
+
10
+#import <React/RCTBridge.h>
11
+#import <React/RCTBundleURLProvider.h>
12
+#import <React/RCTRootView.h>
13
+
14
+@implementation AppDelegate
15
+
16
+- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
17
+{
18
+  RCTBridge *bridge = [[RCTBridge alloc] initWithDelegate:self launchOptions:launchOptions];
19
+  RCTRootView *rootView = [[RCTRootView alloc] initWithBridge:bridge
20
+                                                   moduleName:@"RNPermissionsExample"
21
+                                            initialProperties:nil];
22
+
23
+  rootView.backgroundColor = [[UIColor alloc] initWithRed:1.0f green:1.0f blue:1.0f alpha:1];
24
+
25
+  self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
26
+  UIViewController *rootViewController = [UIViewController new];
27
+  rootViewController.view = rootView;
28
+  self.window.rootViewController = rootViewController;
29
+  [self.window makeKeyAndVisible];
30
+  return YES;
31
+}
32
+
33
+- (NSURL *)sourceURLForBridge:(RCTBridge *)bridge
34
+{
35
+#if DEBUG
36
+  return [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index" fallbackResource:nil];
37
+#else
38
+  return [[NSBundle mainBundle] URLForResource:@"main" withExtension:@"jsbundle"];
39
+#endif
40
+}
41
+
42
+@end

example/ios/Example/Base.lproj/LaunchScreen.xib → example/ios/RNPermissionsExample/Base.lproj/LaunchScreen.xib Vedi File

@@ -18,7 +18,7 @@
18 18
                     <color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
19 19
                     <nil key="highlightedColor"/>
20 20
                 </label>
21
-                <label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Example" textAlignment="center" lineBreakMode="middleTruncation" baselineAdjustment="alignBaselines" minimumFontSize="18" translatesAutoresizingMaskIntoConstraints="NO" id="kId-c2-rCX">
21
+                <label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="RNPermissionsExample" textAlignment="center" lineBreakMode="middleTruncation" baselineAdjustment="alignBaselines" minimumFontSize="18" translatesAutoresizingMaskIntoConstraints="NO" id="kId-c2-rCX">
22 22
                     <rect key="frame" x="20" y="140" width="441" height="43"/>
23 23
                     <fontDescription key="fontDescription" type="boldSystem" pointSize="36"/>
24 24
                     <color key="textColor" cocoaTouchSystemColor="darkTextColor"/>

example/ios/Example/Images.xcassets/AppIcon.appiconset/Contents.json → example/ios/RNPermissionsExample/Images.xcassets/AppIcon.appiconset/Contents.json Vedi File


example/ios/Example/Images.xcassets/Contents.json → example/ios/RNPermissionsExample/Images.xcassets/Contents.json Vedi File


example/ios/Example-tvOS/Info.plist → example/ios/RNPermissionsExample/Info.plist Vedi File

@@ -4,10 +4,12 @@
4 4
 <dict>
5 5
 	<key>CFBundleDevelopmentRegion</key>
6 6
 	<string>en</string>
7
+	<key>CFBundleDisplayName</key>
8
+	<string>RNPermissionsExample</string>
7 9
 	<key>CFBundleExecutable</key>
8 10
 	<string>$(EXECUTABLE_NAME)</string>
9 11
 	<key>CFBundleIdentifier</key>
10
-	<string>org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)</string>
12
+	<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
11 13
 	<key>CFBundleInfoDictionaryVersion</key>
12 14
 	<string>6.0</string>
13 15
 	<key>CFBundleName</key>
@@ -22,6 +24,21 @@
22 24
 	<string>1</string>
23 25
 	<key>LSRequiresIPhoneOS</key>
24 26
 	<true/>
27
+	<key>NSAppTransportSecurity</key>
28
+	<dict>
29
+		<key>NSAllowsArbitraryLoads</key>
30
+		<true/>
31
+		<key>NSExceptionDomains</key>
32
+		<dict>
33
+			<key>localhost</key>
34
+			<dict>
35
+				<key>NSExceptionAllowsInsecureHTTPLoads</key>
36
+				<true/>
37
+			</dict>
38
+		</dict>
39
+	</dict>
40
+	<key>NSLocationWhenInUseUsageDescription</key>
41
+	<string></string>
25 42
 	<key>UILaunchStoryboardName</key>
26 43
 	<string>LaunchScreen</string>
27 44
 	<key>UIRequiredDeviceCapabilities</key>
@@ -36,19 +53,5 @@
36 53
 	</array>
37 54
 	<key>UIViewControllerBasedStatusBarAppearance</key>
38 55
 	<false/>
39
-	<key>NSLocationWhenInUseUsageDescription</key>
40
-	<string></string>
41
-	<key>NSAppTransportSecurity</key>
42
-	<!--See http://ste.vn/2015/06/10/configuring-app-transport-security-ios-9-osx-10-11/ -->
43
-	<dict>
44
-		<key>NSExceptionDomains</key>
45
-		<dict>
46
-			<key>localhost</key>
47
-			<dict>
48
-				<key>NSExceptionAllowsInsecureHTTPLoads</key>
49
-				<true/>
50
-			</dict>
51
-		</dict>
52
-	</dict>
53 56
 </dict>
54 57
 </plist>

+ 16
- 0
example/ios/RNPermissionsExample/main.m Vedi File

@@ -0,0 +1,16 @@
1
+/**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+
8
+#import <UIKit/UIKit.h>
9
+
10
+#import "AppDelegate.h"
11
+
12
+int main(int argc, char * argv[]) {
13
+  @autoreleasepool {
14
+    return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
15
+  }
16
+}

+ 10
- 0
example/metro.config.js Vedi File

@@ -0,0 +1,10 @@
1
+module.exports = {
2
+  transformer: {
3
+    getTransformOptions: async () => ({
4
+      transform: {
5
+        experimentalImportSupport: false,
6
+        inlineRequires: false,
7
+      },
8
+    }),
9
+  },
10
+};

+ 10
- 13
example/package.json Vedi File

@@ -1,23 +1,20 @@
1 1
 {
2
-  "name": "Example",
2
+  "name": "RNPermissionsExample",
3 3
   "version": "0.0.1",
4 4
   "private": true,
5 5
   "scripts": {
6
-    "start": "node node_modules/react-native/local-cli/cli.js start",
7
-    "test": "jest"
6
+    "start": "react-native start",
7
+    "postinstall": "rm -rf node_modules/react-native-permissions/{example,node_modules}",
8
+    "reinstall": "rm -rf node_modules ios/Pods && yarn install && cd ios && pod install"
8 9
   },
9 10
   "dependencies": {
10
-    "react": "16.0.0",
11
-    "react-native": "0.50.3",
12
-    "react-native-permissions": "../"
11
+    "react": "16.8.6",
12
+    "react-native": "0.60.3",
13
+    "react-native-permissions": "file:../"
13 14
   },
14 15
   "devDependencies": {
15
-    "babel-jest": "21.2.0",
16
-    "babel-preset-react-native": "4.0.0",
17
-    "jest": "21.2.1",
18
-    "react-test-renderer": "16.0.0"
19
-  },
20
-  "jest": {
21
-    "preset": "react-native"
16
+    "@babel/core": "7.5.5",
17
+    "@babel/runtime": "7.5.5",
18
+    "metro-react-native-babel-preset": "0.55.0"
22 19
   }
23 20
 }

+ 4689
- 0
example/yarn.lock
File diff suppressed because it is too large
Vedi File