├── .babelrc ├── .editorconfig ├── .eslintignore ├── .eslintrc.yml ├── .gitignore ├── .npmignore ├── LICENSE ├── README.md ├── README_zh-CN.md ├── android ├── .classpath ├── .project ├── build.gradle ├── react-native-dynamic-splash.iml └── src │ └── main │ ├── AndroidManifest.xml │ ├── java │ └── com │ │ └── taumu │ │ └── rnDynamicSplash │ │ ├── DynamicSplash.java │ │ ├── DynamicSplashDownLoad.java │ │ ├── DynamicSplashModule.java │ │ ├── DynamicSplashReactPackage.java │ │ └── utils │ │ ├── Config.java │ │ ├── FileUtils.java │ │ └── HttpUtils.java │ └── res │ ├── layout │ └── splash_dynamic.xml │ └── values │ ├── strings.xml │ └── style.xml ├── demo.android.gif ├── demo.ios.gif ├── example ├── .babelrc ├── .buckconfig ├── .flowconfig ├── .gitattributes ├── .gitignore ├── .watchmanconfig ├── App.js ├── android │ ├── .project │ ├── app │ │ ├── .classpath │ │ ├── .project │ │ ├── BUCK │ │ ├── build.gradle │ │ ├── proguard-rules.pro │ │ └── src │ │ │ └── main │ │ │ ├── AndroidManifest.xml │ │ │ ├── java │ │ │ └── com │ │ │ │ └── example │ │ │ │ ├── MainActivity.java │ │ │ │ └── MainApplication.java │ │ │ └── res │ │ │ ├── mipmap-hdpi │ │ │ └── ic_launcher.png │ │ │ ├── mipmap-mdpi │ │ │ └── ic_launcher.png │ │ │ ├── mipmap-xhdpi │ │ │ └── ic_launcher.png │ │ │ ├── mipmap-xxhdpi │ │ │ └── ic_launcher.png │ │ │ └── values │ │ │ ├── strings.xml │ │ │ └── styles.xml │ ├── build.gradle │ ├── gradle.properties │ ├── gradle │ │ └── wrapper │ │ │ ├── gradle-wrapper.jar │ │ │ └── gradle-wrapper.properties │ ├── gradlew │ ├── gradlew.bat │ ├── keystores │ │ ├── BUCK │ │ └── debug.keystore.properties │ └── settings.gradle ├── app.json ├── index.js ├── ios │ ├── example-tvOS │ │ └── Info.plist │ ├── example-tvOSTests │ │ └── Info.plist │ ├── example.xcodeproj │ │ ├── project.pbxproj │ │ └── xcshareddata │ │ │ └── xcschemes │ │ │ ├── example-tvOS.xcscheme │ │ │ └── example.xcscheme │ ├── example │ │ ├── AppDelegate.h │ │ ├── AppDelegate.m │ │ ├── Base.lproj │ │ │ └── LaunchScreen.xib │ │ ├── Images.xcassets │ │ │ ├── AppIcon.appiconset │ │ │ │ └── Contents.json │ │ │ ├── Contents.json │ │ │ └── Splash.imageset │ │ │ │ ├── Contents.json │ │ │ │ └── splash.png │ │ ├── Info.plist │ │ └── main.m │ └── exampleTests │ │ ├── Info.plist │ │ └── exampleTests.m ├── package-lock.json ├── package.json └── yarn.lock ├── index.js ├── ios ├── RNDynamicSplash.h ├── RNDynamicSplash.m ├── RNDynamicSplash.podspec ├── RNDynamicSplash.xcodeproj │ ├── project.pbxproj │ ├── project.xcworkspace │ │ ├── contents.xcworkspacedata │ │ ├── xcshareddata │ │ │ └── IDEWorkspaceChecks.plist │ │ └── xcuserdata │ │ │ └── mt.xcuserdatad │ │ │ └── UserInterfaceState.xcuserstate │ └── xcuserdata │ │ └── mt.xcuserdatad │ │ └── xcschemes │ │ └── xcschememanagement.plist └── Utils │ ├── FileUtils.h │ ├── FileUtils.m │ ├── HttpUtils.h │ ├── HttpUtils.m │ ├── SplashConfig.h │ ├── SplashConfig.m │ ├── Utils.h │ └── Utils.m ├── package-lock.json └── package.json /.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": ["es2015", "react", "stage-0"], 3 | "plugins": [ 4 | "transform-decorators-legacy" 5 | ] 6 | } 7 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | # 对所有文件生效 4 | [*] 5 | charset = utf-8 6 | indent_style = space 7 | indent_size = 2 8 | end_of_line = lf 9 | insert_final_newline = true 10 | trim_trailing_whitespace = true 11 | 12 | # 对后缀名为 md 的文件生效 13 | [*.md] 14 | trim_trailing_whitespace = false 15 | -------------------------------------------------------------------------------- /.eslintignore: -------------------------------------------------------------------------------- 1 | build/* 2 | public/* 3 | vendor/* 4 | lib/* 5 | example/node_modules/* 6 | -------------------------------------------------------------------------------- /.eslintrc.yml: -------------------------------------------------------------------------------- 1 | extends: airbnb 2 | parser: babel-eslint 3 | env: 4 | es6: true 5 | browser: true 6 | node: true 7 | mocha: true 8 | settings: 9 | import/resolver: 10 | node: 11 | moduleDirectory: 12 | - node_modules 13 | - components 14 | rules: 15 | semi: 16 | - error 17 | - never 18 | arrow-body-style: 0 19 | max-len: 0 20 | global-require: 0 21 | no-console: 0 22 | import/no-dynamic-require: 0 23 | no-use-before-define: 0 24 | no-underscore-dangle: 0 25 | no-class-assign: 0 26 | no-extra-boolean-cast: 0 27 | no-nested-ternary: 0 28 | eol-last: 0 29 | comma-dangle: 30 | - error 31 | - functions: ignore 32 | objects: always-multiline 33 | arrays: always-multiline 34 | jsx-quotes: 35 | - 2 36 | - prefer-single 37 | react/jsx-sort-props: 0 38 | react/jsx-space-before-closing: 0 39 | react/prefer-stateless-function: 0 40 | react/jsx-no-bind: 0 41 | react/jsx-first-prop-new-line: 0 42 | react/jsx-filename-extension: 0 43 | react/react-in-jsx-scope: 0 44 | react/no-multi-comp: 0 45 | react/prop-types: 0 46 | react/self-closing-comp: 0 47 | react/no-string-refs: 0 48 | import/no-extraneous-dependencies: 0 49 | import/prefer-default-export: 0 50 | jsx-a11y/no-static-element-interactions: 0 51 | class-methods-use-this: 0 52 | no-param-reassign: 0 53 | camelcase: 0 54 | no-shadow: 0 55 | no-unused-expressions: 0 56 | no-plusplus: 0 57 | 58 | 59 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules/ 2 | build/ 3 | lib/ 4 | bin/ 5 | 6 | .vscode/ 7 | .idea/ 8 | .gradle/ 9 | .settings/ 10 | -------------------------------------------------------------------------------- /.npmignore: -------------------------------------------------------------------------------- 1 | example/ 2 | src/ 3 | 4 | build 5 | bin 6 | gradle 7 | 8 | .vscode 9 | .idea 10 | .gradle 11 | .settings 12 | 13 | .classpath 14 | .project 15 | 16 | 17 | *.gif 18 | npm-debug.log 19 | 20 | gradlew 21 | gradlew.bat 22 | *.properties 23 | *.iml 24 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018 TaumuLu 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # react-native-dynamic-splash 2 | [以中文查看](./README_zh-CN.md) 3 | React Native dynamic launch page (advertisement page), support for Android and iOS 4 | 5 | ## Installation 6 | ``` 7 | npm install react-native-dynamic-splash --save 8 | ``` 9 | or 10 | ``` 11 | yarn add react-native-dynamic-splash 12 | ``` 13 | 14 | ## Demo 15 | | IOS | Android | 16 | | --- | ------- | 17 | | ![IOS](./demo.ios.gif) | ![Android](./demo.android.gif) | 18 | 19 | ## installation React Native 0.60 20 | 21 | [CLI autolink feature](https://github.com/react-native-community/cli/blob/master/docs/autolinking.md) links the module while building the app. 22 | 23 | 24 | ## installation React Native <= 0.59 25 | 26 | ### Android 27 | 28 | #### Automatic installation 29 | `react-native link react-native-dynamic-splash` 30 | 31 | #### Manual installation 32 | - android/settings.gradle File add code 33 | ```java 34 | include ':react-native-dynamic-splash' 35 | project(':react-native-dynamic-splash').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-dynamic-splash/android') 36 | ``` 37 | 38 | - android/app/build.gradle File add code 39 | ``` 40 | ... 41 | dependencies { 42 | ... 43 | compile project(':react-native-dynamic-splash') 44 | } 45 | ... 46 | ``` 47 | 48 | - android/app/src/main/java/com/example/MainApplication.java File add code 49 | ```java 50 | ... 51 | import com.taumu.rnDynamicSplash.DynamicSplashReactPackage; // Import package 52 | 53 | public class MainApplication extends Application implements ReactApplication { 54 | ... 55 | private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) { 56 | @Override 57 | public boolean getUseDeveloperSupport() { 58 | return BuildConfig.DEBUG; 59 | } 60 | 61 | @Override 62 | protected List getPackages() { 63 | return Arrays.asList( 64 | new MainReactPackage(), 65 | new DynamicSplashReactPackage() // Add here 66 | ); 67 | } 68 | 69 | @Override 70 | protected String getJSMainModuleName() { 71 | return "index"; 72 | } 73 | }; 74 | ... 75 | } 76 | ``` 77 | 78 | ### iOS 79 | 80 | #### Installing via CocoaPods 81 | 1. Added in Podfile file `pod 'RNDynamicSplash', :path => '../node_modules/react-native-dynamic-splash'` 82 | 3. Then run pod install 83 | 84 | #### Manual installation 85 | 1. In XCode, in the project navigator, right click Libraries ➜ Add Files to [your project's name] 86 | 2. Go to node_modules ➜ react-native-dynamic-splash and add RNDynamicSplash.xcodeproj 87 | 3. In XCode, in the project navigator, select your targets. Add libRNDynamicSplash.a to your project's Build Phases ➜ Link Binary With Libraries 88 | 4. To fix 'RNDynamicSplash.h' file not found, you have to select your project/targets → Build Settings → Search Paths → Header Search Paths to add: 89 | - project $(SRCROOT)/../node_modules/react-native-dynamic-splash/ios recursive 90 | - targets $(inherited) recursive 91 | 92 | ## Usage 93 | 94 | ### Android 95 | - MainActivity.java File 96 | ```java 97 | ... 98 | import com.taumu.rnDynamicSplash.DynamicSplash; 99 | import com.taumu.rnDynamicSplash.utils.Config; 100 | 101 | public class MainActivity extends ReactActivity { 102 | ... 103 | @Override 104 | protected void onCreate(Bundle savedInstanceState) { 105 | Config splashConfig = new Config(); // Splash configuration class 106 | // splashConfig.setImageUrl("http://custom/splash.png"); 107 | splashConfig.setAutoHide(true); 108 | // splashConfig.setAutoHideTime(2000); 109 | // splashConfig.setLayoutResID(R.layout.custom_splash_dynamic); 110 | // splashConfig.setThemeResId(R.style.Custom_Splash_Theme); 111 | // splashConfig.setAutoDownload(false); 112 | // splashConfig.setSplashSavePath("/customSplashPath/"); 113 | // splashConfig.setDynamicShow(false); 114 | new DynamicSplash(this, splashConfig); // Add display splash here 115 | super.onCreate(savedInstanceState); 116 | } 117 | ... 118 | } 119 | ``` 120 | 121 | ### iOS 122 | - AppDelegate.m File 123 | ```objective-c 124 | ... 125 | #import "RNDynamicSplash.h" 126 | #import "SplashConfig.h" 127 | 128 | @implementation AppDelegate 129 | 130 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 131 | { 132 | ... 133 | [self.window makeKeyAndVisible]; 134 | 135 | SplashConfig *config = [[SplashConfig alloc] init]; // Splash configuration class 136 | // config.imageUrl = @"http://custom/splash.png"; 137 | config.autoHide = true; 138 | // config.autoHideTime = 1000; 139 | // config.dynamicShow = false; 140 | // config.autoDownload = false; 141 | // config.splashSavePath = @"custom"; 142 | [[RNDynamicSplash alloc] initWithShow:rootView splashConfig:config]; // Add display splash here 143 | 144 | return YES; 145 | } 146 | 147 | @end 148 | ... 149 | ``` 150 | 151 | ### Configuration 152 | | type | Field | defaultValue | setter | description | 153 | | ---- | ----- | ------------ | ------ | ----------- | 154 | | String | imageUrl | "" | setImageUrl | Download picture address | 155 | | String | splashSavePath | /splash/ | setSplashSavePath | Save image address | 156 | | int | themeResId(Android only) | R.style.DynamicSplash_Theme | setThemeResId | Use theme resource id | 157 | | int | layoutResId(Android only) | R.layout.splash_dynamic | setLayoutResId | Use layout file resource id | 158 | | boolean | autoDownload | true | setAutoDownload | Whether to download automatically | 159 | | boolean | dynamicShow | true | setDynamicShow | Whether to display the downloaded picture | 160 | | boolean | autoHide | false | setAutoHide | Whether to automatically hide | 161 | | long | autoHideTime | 3000 | setAutoHideTime | Automatically hide time | 162 | 163 | ### Other instructions 164 | - The first time to start displaying the default image, the second time to start displaying the downloaded image again 165 | - Android Can use their own written resource files and topics, and the same name as the default configuration, otherwise call the set method to change the configuration, reference package resource file 166 | - Android doesn't set imageUrl to show resource image in layout file 167 | - ios does not set imageUrl to show picture of LaunchImage 168 | 169 | #### Provide get request method 170 | Can call the request to get the address of the picture 171 | ```java 172 | // mock json data 173 | // { 174 | // splashInfo: { 175 | // imageUrl: "http://***.png" 176 | // } 177 | // } 178 | ... 179 | import com.taumu.rnDynamicSplash.utils.HttpUtils; 180 | 181 | public static void getSplashImageUrl(String getApi) { 182 | HttpUtils.get(getApi, new HttpUtils.Callback() { 183 | @Override 184 | public void onResponse(String jsonString) { 185 | try { 186 | JSONObject jsonObject = new JSONObject(jsonString); 187 | JSONObject valueObject = jsonObject.getJSONObject("splashInfo"); 188 | String imageUrl = valueObject.getString("imageUrl"); 189 | if (!TextUtils.isEmpty(imageUrl)) { 190 | Config splashConfig = new Config(); 191 | splashConfig.setImageUrl(imageUrl); 192 | new DynamicSplash(activity, splashConfig); 193 | } 194 | } catch (JSONException e) { 195 | e.printStackTrace(); 196 | } 197 | } 198 | }); 199 | } 200 | ... 201 | ``` 202 | 203 | ## API 204 | | name | type | description | conflict | 205 | | ---- | ---- | ----------- | -------- | 206 | | hide() | function | Js control hidden splash | autoHide not set true | 207 | | downloadSplash() | function | Js control download pictures | autoDownload is set to false | 208 | 209 | ## TODO 210 | - [x] Android version splash 211 | - [x] Ios version splash 212 | - [ ] js incoming url as image download link 213 | - [ ] Configuration add skip button 214 | - [ ] Ios rewrite using swift 215 | 216 | ## Changelog 217 | - 1.0.* 218 | - 1.1.* 219 | -------------------------------------------------------------------------------- /README_zh-CN.md: -------------------------------------------------------------------------------- 1 | # react-native-dynamic-splash 2 | React Native动态启动页(广告页),支持Android和iOS 3 | 4 | ## 安装 5 | ``` 6 | npm install react-native-dynamic-splash --save 7 | ``` 8 | 9 | ## Demo 10 | | IOS | Android | 11 | | --- | ------- | 12 | | ![IOS](./demo.ios.gif) | ![Android](./demo.android.gif) | 13 | 14 | ## RN安装 15 | 16 | ### Android 17 | 18 | #### 自动安装 19 | `react-native link react-native-dynamic-splash` 20 | 21 | #### 手动安装 22 | - android/settings.gradle 文件添加代码 23 | ```java 24 | include ':react-native-dynamic-splash' 25 | project(':react-native-dynamic-splash').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-dynamic-splash/android') 26 | ``` 27 | 28 | - android/app/build.gradle 文件添加代码 29 | ``` 30 | ... 31 | dependencies { 32 | ... 33 | compile project(':react-native-dynamic-splash') 34 | } 35 | ... 36 | ``` 37 | 38 | - android/app/src/main/java/com/example/MainApplication.java 文件添加代码 39 | ```java 40 | ... 41 | import com.taumu.rnDynamicSplash.DynamicSplashReactPackage; // 引入包 42 | 43 | public class MainApplication extends Application implements ReactApplication { 44 | ... 45 | private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) { 46 | @Override 47 | public boolean getUseDeveloperSupport() { 48 | return BuildConfig.DEBUG; 49 | } 50 | 51 | @Override 52 | protected List getPackages() { 53 | return Arrays.asList( 54 | new MainReactPackage(), 55 | new DynamicSplashReactPackage() // 在此添加 56 | ); 57 | } 58 | 59 | @Override 60 | protected String getJSMainModuleName() { 61 | return "index"; 62 | } 63 | }; 64 | ... 65 | } 66 | ``` 67 | 68 | ### iOS 69 | 70 | #### 通过CocoaPods安装 71 | 1. Podfile文件中添加 `pod 'RNDynamicSplash', :path => '../node_modules/react-native-dynamic-splash'` 72 | 3. 运行 pod install 73 | 74 | #### 手动安装 75 | 1. 在XCode中的项目导航器中,右键单击 Libraries ➜ Add Files to [your project's name] 76 | 2. 转到 node_modules ➜ react-native-dynamic-splash 并添加 RNDynamicSplash.xcodeproj 77 | 3. 在XCode中的项目导航器中,选择targets 添加 libRNDynamicSplash.a 到你的项目,在 Build Phases ➜ Link Binary With Libraries中 78 | 4. 修复 'RNDynamicSplash.h' 头文件找不到, 必须选择 project/targets → Build Settings → Search Paths → Header Search Paths to add: 79 | - project $(SRCROOT)/../node_modules/react-native-dynamic-splash/ios recursive 80 | - targets $(inherited) recursive 81 | 82 | 83 | ## 使用 84 | 85 | ### Android 86 | - MainActivity.java 文件 87 | ```java 88 | ... 89 | import com.taumu.rnDynamicSplash.DynamicSplash; 90 | import com.taumu.rnDynamicSplash.utils.Config; 91 | 92 | public class MainActivity extends ReactActivity { 93 | ... 94 | @Override 95 | protected void onCreate(Bundle savedInstanceState) { 96 | Config splashConfig = new Config(); // splash配置类 97 | // splashConfig.setImageUrl("http://custom/splash.png"); 98 | splashConfig.setAutoHide(true); 99 | // splashConfig.setAutoHideTime(2000); 100 | // splashConfig.setLayoutResID(R.layout.custom_splash_dynamic); 101 | // splashConfig.setThemeResId(R.style.Custom_Splash_Theme); 102 | // splashConfig.setAutoDownload(false); 103 | // splashConfig.setSplashSavePath("/customSplashPath/"); 104 | // splashConfig.setDynamicShow(false); 105 | new DynamicSplash(this, splashConfig); // 在此添加展示splash 106 | super.onCreate(savedInstanceState); 107 | } 108 | ... 109 | } 110 | ``` 111 | 112 | ### iOS 113 | - AppDelegate.m 文件 114 | ```objective-c 115 | ... 116 | #import "RNDynamicSplash.h" 117 | #import "SplashConfig.h" 118 | 119 | @implementation AppDelegate 120 | 121 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 122 | { 123 | ... 124 | [self.window makeKeyAndVisible]; 125 | 126 | SplashConfig *config = [[SplashConfig alloc] init]; // splash配置类 127 | // config.imageUrl = @"http://custom/splash.png"; 128 | config.autoHide = true; 129 | // config.autoHideTime = 1000; 130 | // config.dynamicShow = false; 131 | // config.autoDownload = false; 132 | // config.splashSavePath = @"custom"; 133 | [[RNDynamicSplash alloc] initWithShow:rootView splashConfig:config]; // 在此添加展示splash 134 | 135 | return YES; 136 | } 137 | 138 | @end 139 | ... 140 | ``` 141 | 142 | ### 配置项 143 | | type | Field | defaultValue | setter | description | 144 | | ---- | ----- | ------------ | ------ | ----------- | 145 | | String | imageUrl | "" | setImageUrl | 下载图片地址 | 146 | | String | splashSavePath | /splash/ | setSplashSavePath | 保存图片地址 | 147 | | int | themeResId(Android only) | R.style.DynamicSplash_Theme | setThemeResId | 使用主题资源id | 148 | | int | layoutResId(Android only) | R.layout.splash_dynamic | setLayoutResId | 使用布局文件资源id | 149 | | boolean | autoDownload | true | setAutoDownload | 是否自动下载 | 150 | | boolean | dynamicShow | true | setDynamicShow | 是否展示下载的图片 | 151 | | boolean | autoHide | false | setAutoHide | 是否自动隐藏 | 152 | | long | autoHideTime | 3000 | setAutoHideTime | 自动隐藏时间 | 153 | 154 | ### 其他说明 155 | - 第一次启动展示默认图片,第二次再次启动展示下载好的图片 156 | - android可以用自己写的资源文件和主题,可以和默认的配置同名,否则调用set方法更改配置,参考包中的资源文件 157 | - android未设置imageUrl将展示布局文件中的资源图片 158 | - ios未设置imageUrl将展示LaunchImage的图片 159 | 160 | 161 | #### 提供get请求方法 162 | 可以调用请求以取获取图片地址 163 | ```java 164 | // mock json data 165 | // { 166 | // splashInfo: { 167 | // imageUrl: "http://***.png" 168 | // } 169 | // } 170 | ... 171 | import com.taumu.rnDynamicSplash.utils.HttpUtils; 172 | 173 | public static void getSplashImageUrl(String getApi) { 174 | HttpUtils.get(getApi, new HttpUtils.Callback() { 175 | @Override 176 | public void onResponse(String jsonString) { 177 | try { 178 | JSONObject jsonObject = new JSONObject(jsonString); 179 | JSONObject valueObject = jsonObject.getJSONObject("splashInfo"); 180 | String imageUrl = valueObject.getString("imageUrl"); 181 | if (!TextUtils.isEmpty(imageUrl)) { 182 | Config splashConfig = new Config(); 183 | splashConfig.setImageUrl(imageUrl); 184 | new DynamicSplash(activity, splashConfig); 185 | } 186 | } catch (JSONException e) { 187 | e.printStackTrace(); 188 | } 189 | } 190 | }); 191 | } 192 | ... 193 | ``` 194 | 195 | ## API 196 | | name | type | description | conflict | 197 | | ---- | ---- | ----------- | -------- | 198 | | hide() | function | js控制隐藏splash | autoHide不要设置true | 199 | | downloadSplash() | function | js控制下载图片 | autoDownload要设置为false | 200 | 201 | ## TODO 202 | - [x] android版本splash 203 | - [x] ios版本splash 204 | - [ ] js中传入url作为图片下载链接 205 | - [ ] 配置添加跳过按钮 206 | - [ ] ios使用swift重写 207 | 208 | ## Changelog 209 | - 1.0.* 210 | - 1.1.* 211 | -------------------------------------------------------------------------------- /android/.classpath: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /android/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | react-native-dynamic-splash 4 | Project react-native-dynamic-splash created by Buildship. 5 | 6 | 7 | 8 | 9 | org.eclipse.jdt.core.javabuilder 10 | 11 | 12 | 13 | 14 | org.eclipse.buildship.core.gradleprojectbuilder 15 | 16 | 17 | 18 | 19 | 20 | org.eclipse.jdt.core.javanature 21 | org.eclipse.buildship.core.gradleprojectnature 22 | 23 | 24 | -------------------------------------------------------------------------------- /android/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.library' 2 | 3 | def safeExtGet(prop, fallback) { 4 | rootProject.ext.has(prop) ? rootProject.ext.get(prop) : fallback 5 | } 6 | 7 | android { 8 | compileSdkVersion safeExtGet('compileSdkVersion', 28) 9 | buildToolsVersion safeExtGet('buildToolsVersion', "28.0.3") 10 | 11 | defaultConfig { 12 | minSdkVersion safeExtGet('minSdkVersion', 16) 13 | targetSdkVersion safeExtGet('targetSdkVersion', 28) 14 | versionCode 1 15 | versionName "1.0" 16 | } 17 | } 18 | 19 | dependencies { 20 | implementation "com.facebook.react:react-native:${safeExtGet('reactNativeVersion', '+')}" 21 | } 22 | -------------------------------------------------------------------------------- /android/react-native-dynamic-splash.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 8 | 9 | 10 | 11 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 | 125 | 126 | 127 | 128 | 129 | 130 | 131 | 132 | 133 | 134 | -------------------------------------------------------------------------------- /android/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | -------------------------------------------------------------------------------- /android/src/main/java/com/taumu/rnDynamicSplash/DynamicSplash.java: -------------------------------------------------------------------------------- 1 | package com.taumu.rnDynamicSplash; 2 | 3 | import android.app.Activity; 4 | import android.app.Dialog; 5 | import android.os.Handler; 6 | import android.widget.ImageView; 7 | 8 | import java.lang.ref.WeakReference; 9 | 10 | import com.taumu.rnDynamicSplash.utils.Config; 11 | 12 | 13 | public class DynamicSplash { 14 | private static Dialog mDialog; 15 | private static WeakReference mActivity; 16 | private static ImageView mSplashImage; 17 | 18 | public static DynamicSplash mDynamicSplash; 19 | public static Config mConfig; 20 | 21 | public DynamicSplash(Activity activity) { 22 | this(activity, new Config()); 23 | } 24 | 25 | public DynamicSplash(final Activity activity, Config config) { 26 | if (activity == null) return; 27 | if (config == null) { 28 | config = new Config(); 29 | } 30 | final Config finalConfig = setConfigField(activity, config); 31 | mConfig = finalConfig; 32 | mDynamicSplash = this; 33 | mActivity = new WeakReference(activity); 34 | 35 | activity.runOnUiThread(new Runnable() { 36 | @Override 37 | public void run() { 38 | if (!activity.isFinishing()) { 39 | mDialog = new Dialog(activity, finalConfig.getThemeResId()); 40 | mDialog.setContentView(finalConfig.getLayoutResId()); 41 | mDialog.setCancelable(false); 42 | mSplashImage = (ImageView) mDialog.findViewById(R.id.dynamicSplash_id); 43 | mSplashImage.setBackgroundColor(mConfig.getColor()); 44 | 45 | if (finalConfig.isDynamicShow()) { 46 | DynamicSplashDownLoad.setDialogImage(activity, mSplashImage); 47 | } 48 | if (finalConfig.isAutoDownload()) { 49 | downloadSplash(activity); 50 | } 51 | 52 | if (!mDialog.isShowing()) { 53 | mDialog.show(); 54 | if (finalConfig.isAutoHide()) { 55 | autoHide(activity); 56 | } 57 | } 58 | } 59 | } 60 | }); 61 | } 62 | 63 | private void autoHide(final Activity activity) { 64 | Handler handler = new Handler(); 65 | handler.postDelayed(new Runnable() { 66 | @Override 67 | public void run() { 68 | hide(activity); 69 | } 70 | }, mConfig.getAutoHideTime()); 71 | } 72 | 73 | private Config setConfigField(Activity activity, Config config) { 74 | String savePath = config.getSplashSavePath(); 75 | if (!savePath.startsWith("/")) { 76 | savePath = "/" + savePath; 77 | } 78 | if (!savePath.endsWith("/")) { 79 | savePath = savePath + "/"; 80 | } 81 | savePath = activity.getApplication().getFilesDir().getAbsolutePath() + savePath; 82 | config.setSplashSavePath(savePath); 83 | return config; 84 | } 85 | 86 | public void downloadSplash(Activity activity) { 87 | DynamicSplashDownLoad.downloadSplash(activity); 88 | } 89 | 90 | public void hide(Activity activity) { 91 | if (activity == null) { 92 | if (mActivity == null) { 93 | return; 94 | } 95 | activity = mActivity.get(); 96 | } 97 | if (activity == null) return; 98 | activity.runOnUiThread(new Runnable() { 99 | @Override 100 | public void run() { 101 | if (mDialog != null && mDialog.isShowing()) { 102 | mDialog.dismiss(); 103 | mDialog = null; 104 | } 105 | } 106 | }); 107 | } 108 | } 109 | -------------------------------------------------------------------------------- /android/src/main/java/com/taumu/rnDynamicSplash/DynamicSplashDownLoad.java: -------------------------------------------------------------------------------- 1 | package com.taumu.rnDynamicSplash; 2 | 3 | import android.app.Activity; 4 | import android.content.Context; 5 | import android.content.SharedPreferences; 6 | import android.graphics.Bitmap; 7 | import android.os.AsyncTask; 8 | import android.text.TextUtils; 9 | import android.util.Log; 10 | import android.widget.ImageView; 11 | import java.io.File; 12 | 13 | import static com.taumu.rnDynamicSplash.utils.FileUtils.*; 14 | import static com.taumu.rnDynamicSplash.DynamicSplash.mConfig; 15 | 16 | public class DynamicSplashDownLoad { 17 | private static String sharedName = "dynamicSplashConfig"; 18 | private static String sharedKeyName = "fileName"; 19 | 20 | public static void setSharedValue(Activity activity, String value) { 21 | SharedPreferences sharedPre = activity.getSharedPreferences(sharedName, Context.MODE_PRIVATE); 22 | SharedPreferences.Editor editor = sharedPre.edit(); 23 | editor.putString(sharedKeyName, value); 24 | editor.apply(); 25 | } 26 | 27 | public static String getSharedValue(Activity activity) { 28 | SharedPreferences sharedPre = activity.getSharedPreferences(sharedName, Context.MODE_PRIVATE); 29 | return sharedPre.getString(sharedKeyName, ""); 30 | } 31 | 32 | public static void downloadSplash(Activity activity) { 33 | String imageUrl = mConfig.getImageUrl(); 34 | if (imageUrl != null && !imageUrl.equals("")) { 35 | String fileName = getFileName(imageUrl); 36 | try { 37 | File imageFile = new File(mConfig.getSplashSavePath() + fileName); 38 | 39 | if (!imageFile.exists()) { 40 | new DownloadAsyncTask().execute(imageUrl); 41 | } 42 | setSharedValue(activity, fileName); 43 | } catch (Exception e) { 44 | e.printStackTrace(); 45 | } 46 | } 47 | } 48 | 49 | public static void setDialogImage(Activity activity, ImageView imageView) { 50 | String fileName = getSharedValue(activity); 51 | 52 | if (!TextUtils.isEmpty(fileName)) { 53 | String filePath = mConfig.getSplashSavePath() + fileName; 54 | Bitmap loacalBitmap = getLoacalBitmap(filePath); 55 | 56 | if (loacalBitmap != null) { 57 | imageView.setImageBitmap(loacalBitmap); 58 | Log.d("SplashDownLoad", "本地获取"); 59 | } 60 | } 61 | } 62 | 63 | static class DownloadAsyncTask extends AsyncTask { 64 | @Override 65 | protected void onPreExecute() { 66 | super.onPreExecute(); 67 | } 68 | 69 | @Override 70 | protected Bitmap doInBackground(String... params) { 71 | Bitmap b = getBitmapByUrl(params[0]); 72 | return b; 73 | } 74 | 75 | @Override 76 | protected void onPostExecute(Bitmap result) { 77 | super.onPostExecute(result); 78 | if (result != null) { 79 | File file = saveImage(result, mConfig.getSplashSavePath(), getFileName(mConfig.getImageUrl())); 80 | Log.d("SplashDownLoad", file.toString()); 81 | } 82 | } 83 | } 84 | } 85 | -------------------------------------------------------------------------------- /android/src/main/java/com/taumu/rnDynamicSplash/DynamicSplashModule.java: -------------------------------------------------------------------------------- 1 | package com.taumu.rnDynamicSplash; 2 | 3 | import com.facebook.react.bridge.ReactApplicationContext; 4 | import com.facebook.react.bridge.ReactContextBaseJavaModule; 5 | import com.facebook.react.bridge.ReactMethod; 6 | 7 | import static com.taumu.rnDynamicSplash.DynamicSplash.mDynamicSplash; 8 | 9 | public class DynamicSplashModule extends ReactContextBaseJavaModule { 10 | public DynamicSplashModule(ReactApplicationContext reactContext) { 11 | super(reactContext); 12 | } 13 | 14 | @Override 15 | public String getName() { 16 | return "DynamicSplash"; 17 | } 18 | 19 | // @ReactMethod 20 | // public void show() { 21 | // mDynamicSplash.show(getCurrentActivity()); 22 | // } 23 | 24 | @ReactMethod 25 | public void downloadSplash() { 26 | mDynamicSplash.downloadSplash(getCurrentActivity()); 27 | } 28 | 29 | @ReactMethod 30 | public void hide() { 31 | mDynamicSplash.hide(getCurrentActivity()); 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /android/src/main/java/com/taumu/rnDynamicSplash/DynamicSplashReactPackage.java: -------------------------------------------------------------------------------- 1 | package com.taumu.rnDynamicSplash; 2 | 3 | import com.facebook.react.ReactPackage; 4 | import com.facebook.react.bridge.JavaScriptModule; 5 | import com.facebook.react.bridge.NativeModule; 6 | import com.facebook.react.bridge.ReactApplicationContext; 7 | import com.facebook.react.uimanager.ViewManager; 8 | 9 | import java.util.ArrayList; 10 | import java.util.Collections; 11 | import java.util.List; 12 | 13 | public class DynamicSplashReactPackage implements ReactPackage { 14 | 15 | // Deprecated RN 0.47 16 | public List> createJSModules() { 17 | return Collections.emptyList(); 18 | } 19 | 20 | @Override 21 | public List createViewManagers(ReactApplicationContext reactContext) { 22 | return Collections.emptyList(); 23 | } 24 | 25 | @Override 26 | public List createNativeModules( 27 | ReactApplicationContext reactContext) { 28 | List modules = new ArrayList<>(); 29 | modules.add(new DynamicSplashModule(reactContext)); 30 | return modules; 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /android/src/main/java/com/taumu/rnDynamicSplash/utils/Config.java: -------------------------------------------------------------------------------- 1 | package com.taumu.rnDynamicSplash.utils; 2 | 3 | import com.taumu.rnDynamicSplash.R; 4 | 5 | public class Config { 6 | private String imageUrl = ""; 7 | private int color = 0; 8 | private String splashSavePath = "/splash/"; 9 | private int themeResId = R.style.DynamicSplash_Theme; 10 | private int layoutResId = R.layout.splash_dynamic; 11 | private boolean autoDownload = true; 12 | private boolean dynamicShow = true; 13 | private boolean autoHide = false; 14 | private long autoHideTime = 3000; 15 | 16 | public int getColor() { 17 | return color; 18 | } 19 | 20 | public void setColor(int color) { 21 | this.color = color; 22 | } 23 | 24 | public String getImageUrl() { 25 | return imageUrl; 26 | } 27 | 28 | public void setImageUrl(String imageUrl) { 29 | this.imageUrl = imageUrl; 30 | } 31 | 32 | public int getThemeResId() { 33 | return themeResId; 34 | } 35 | 36 | public void setThemeResId(int themeResId) { 37 | this.themeResId = themeResId; 38 | } 39 | 40 | public String getSplashSavePath() { 41 | return splashSavePath; 42 | } 43 | 44 | public void setSplashSavePath(String splashSavePath) { 45 | this.splashSavePath = splashSavePath; 46 | } 47 | 48 | public boolean isAutoDownload() { 49 | return autoDownload; 50 | } 51 | 52 | public void setAutoDownload(boolean autoDownload) { 53 | this.autoDownload = autoDownload; 54 | } 55 | 56 | public boolean isAutoHide() { 57 | return autoHide; 58 | } 59 | 60 | public void setAutoHide(boolean autoHide) { 61 | this.autoHide = autoHide; 62 | } 63 | 64 | public long getAutoHideTime() { 65 | return autoHideTime; 66 | } 67 | 68 | public void setAutoHideTime(long autoHideTime) { 69 | this.autoHideTime = autoHideTime; 70 | } 71 | 72 | public boolean isDynamicShow() { 73 | return dynamicShow; 74 | } 75 | 76 | public void setDynamicShow(boolean dynamicShow) { 77 | this.dynamicShow = dynamicShow; 78 | } 79 | 80 | public int getLayoutResId() { 81 | return layoutResId; 82 | } 83 | 84 | public void setLayoutResId(int layoutResId) { 85 | this.layoutResId = layoutResId; 86 | } 87 | } 88 | -------------------------------------------------------------------------------- /android/src/main/java/com/taumu/rnDynamicSplash/utils/FileUtils.java: -------------------------------------------------------------------------------- 1 | package com.taumu.rnDynamicSplash.utils; 2 | 3 | import android.graphics.Bitmap; 4 | import android.graphics.BitmapFactory; 5 | 6 | import java.io.File; 7 | import java.io.FileInputStream; 8 | import java.io.FileNotFoundException; 9 | import java.io.FileOutputStream; 10 | import java.io.IOException; 11 | import java.io.InputStream; 12 | import java.net.HttpURLConnection; 13 | import java.net.URL; 14 | 15 | public class FileUtils { 16 | 17 | public static String getFileName(String url) { 18 | int index = url.lastIndexOf("/") + 1; 19 | return url.substring(index); 20 | } 21 | 22 | public static Bitmap getLoacalBitmap(String url) { 23 | if (url != null) { 24 | FileInputStream fis = null; 25 | try { 26 | fis = new FileInputStream(url); 27 | return BitmapFactory.decodeStream(fis); // /把流转化为Bitmap图片 28 | } catch (FileNotFoundException e) { 29 | e.printStackTrace(); 30 | return null; 31 | } finally { 32 | if (fis != null) { 33 | try { 34 | fis.close(); 35 | } catch (IOException e) { 36 | e.printStackTrace(); 37 | } 38 | } 39 | } 40 | } else { 41 | return null; 42 | } 43 | } 44 | 45 | public static Bitmap getBitmapByUrl(final String url) { 46 | URL fileUrl; 47 | InputStream is = null; 48 | Bitmap bitmap = null; 49 | try { 50 | fileUrl = new URL(url); 51 | HttpURLConnection conn = (HttpURLConnection) fileUrl.openConnection(); 52 | conn.setDoInput(true); 53 | conn.connect(); 54 | is = conn.getInputStream(); 55 | bitmap = BitmapFactory.decodeStream(is); 56 | } catch (Exception e) { 57 | e.printStackTrace(); 58 | } finally { 59 | try { 60 | if (null != is) { 61 | is.close(); 62 | } 63 | } catch (IOException e) { 64 | e.printStackTrace(); 65 | } 66 | } 67 | return bitmap; 68 | } 69 | 70 | public static boolean deleteFile(String fileName) { 71 | File file = new File(fileName); 72 | // 如果文件路径所对应的文件存在,并且是一个文件,则直接删除 73 | if (file.exists() && file.isFile()) { 74 | if (file.delete()) { 75 | return true; 76 | } else { 77 | return false; 78 | } 79 | } else { 80 | return false; 81 | } 82 | } 83 | 84 | //保存图片到本地路径 85 | public static File saveImage(Bitmap bmp, String filePath, String fileName) { 86 | File appDir = new File(filePath); 87 | if (!appDir.exists()) { 88 | appDir.mkdir(); 89 | } 90 | File[] files = appDir.listFiles(); 91 | for (int i = 0; i < files.length; i++) { 92 | deleteFile(files[i].getAbsolutePath()); 93 | } 94 | 95 | File file = new File(appDir, fileName); 96 | try { 97 | // if(file.exists()){ 98 | // file.delete(); 99 | // } 100 | // file.createNewFile(); 101 | FileOutputStream fos = new FileOutputStream(file); 102 | // JPEG 103 | bmp.compress(Bitmap.CompressFormat.PNG, 100, fos); 104 | fos.flush(); 105 | fos.close(); 106 | } catch (FileNotFoundException e) { 107 | e.printStackTrace(); 108 | } catch (IOException e) { 109 | e.printStackTrace(); 110 | } 111 | return file; 112 | } 113 | } 114 | -------------------------------------------------------------------------------- /android/src/main/java/com/taumu/rnDynamicSplash/utils/HttpUtils.java: -------------------------------------------------------------------------------- 1 | package com.taumu.rnDynamicSplash.utils; 2 | 3 | import android.os.Handler; 4 | 5 | import java.io.ByteArrayOutputStream; 6 | import java.io.IOException; 7 | import java.io.InputStream; 8 | import java.net.HttpURLConnection; 9 | import java.net.URL; 10 | 11 | public class HttpUtils { 12 | public interface Callback { 13 | void onResponse(String jsonString); 14 | } 15 | 16 | public static void get(final String requestUrl, final Callback callback) { 17 | final Handler handler = new Handler(); 18 | 19 | new Thread(new Runnable() { 20 | @Override 21 | public void run() { 22 | try { 23 | URL url = new URL(requestUrl); 24 | HttpURLConnection connection = (HttpURLConnection) url.openConnection(); 25 | connection.setConnectTimeout(5000); 26 | connection.setRequestMethod("GET"); 27 | //获得结果码 28 | int responseCode = connection.getResponseCode(); 29 | if (responseCode == 200) { 30 | //请求成功 获得返回的流 31 | InputStream is = connection.getInputStream(); 32 | byte[] data = readStream(is); 33 | final String json = new String(data); 34 | handler.post(new Runnable() { 35 | @Override 36 | public void run() { 37 | callback.onResponse(json); 38 | } 39 | }); 40 | } else { 41 | //请求失败 42 | } 43 | } catch (Exception e) { 44 | e.printStackTrace(); 45 | } 46 | } 47 | }).start(); 48 | } 49 | 50 | public static byte[] readStream(InputStream input) throws IOException { 51 | ByteArrayOutputStream output = new ByteArrayOutputStream(); 52 | byte[] buffer = new byte[4096]; 53 | int n; 54 | while (-1 != (n = input.read(buffer))) { 55 | output.write(buffer, 0, n); 56 | } 57 | return output.toByteArray(); 58 | } 59 | } 60 | -------------------------------------------------------------------------------- /android/src/main/res/layout/splash_dynamic.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 14 | 15 | -------------------------------------------------------------------------------- /android/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | react-native-dynamic-splash 3 | 4 | -------------------------------------------------------------------------------- /android/src/main/res/values/style.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 8 | 9 | 10 | 13 | 14 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /demo.android.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TaumuLu/react-native-dynamic-splash/a3d368126f8ab1152c29ec0d65a311a8ee8b5593/demo.android.gif -------------------------------------------------------------------------------- /demo.ios.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TaumuLu/react-native-dynamic-splash/a3d368126f8ab1152c29ec0d65a311a8ee8b5593/demo.ios.gif -------------------------------------------------------------------------------- /example/.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": ["react-native"] 3 | } 4 | -------------------------------------------------------------------------------- /example/.buckconfig: -------------------------------------------------------------------------------- 1 | 2 | [android] 3 | target = Google Inc.:Google APIs:23 4 | 5 | [maven_repositories] 6 | central = https://repo1.maven.org/maven2 7 | -------------------------------------------------------------------------------- /example/.flowconfig: -------------------------------------------------------------------------------- 1 | [ignore] 2 | ; We fork some components by platform 3 | .*/*[.]android.js 4 | 5 | ; Ignore "BUCK" generated dirs 6 | /\.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 | ; Ignore metro 20 | .*/node_modules/metro/.* 21 | 22 | [include] 23 | 24 | [libs] 25 | node_modules/react-native/Libraries/react-native/react-native-interface.js 26 | node_modules/react-native/flow/ 27 | node_modules/react-native/flow-github/ 28 | 29 | [options] 30 | emoji=true 31 | 32 | module.system=haste 33 | 34 | munge_underscores=true 35 | 36 | 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' 37 | 38 | module.file_ext=.js 39 | module.file_ext=.jsx 40 | module.file_ext=.json 41 | module.file_ext=.native.js 42 | 43 | suppress_type=$FlowIssue 44 | suppress_type=$FlowFixMe 45 | suppress_type=$FlowFixMeProps 46 | suppress_type=$FlowFixMeState 47 | 48 | suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\) 49 | suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+ 50 | suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy 51 | suppress_comment=\\(.\\|\n\\)*\\$FlowExpectedError 52 | 53 | [version] 54 | ^0.67.0 55 | -------------------------------------------------------------------------------- /example/.gitattributes: -------------------------------------------------------------------------------- 1 | *.pbxproj -text 2 | -------------------------------------------------------------------------------- /example/.gitignore: -------------------------------------------------------------------------------- 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 54 | 55 | # Bundle artifact 56 | *.jsbundle 57 | -------------------------------------------------------------------------------- /example/.watchmanconfig: -------------------------------------------------------------------------------- 1 | {} -------------------------------------------------------------------------------- /example/App.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Sample React Native App 3 | * https://github.com/facebook/react-native 4 | * @flow 5 | */ 6 | 7 | import React, { Component } from 'react'; 8 | 9 | import { 10 | Platform, 11 | StyleSheet, 12 | Text, 13 | View, 14 | NativeModules 15 | } from 'react-native'; 16 | 17 | const instructions = Platform.select({ 18 | ios: 'Press Cmd+R to reload,\n' + 19 | 'Cmd+D or shake for dev menu', 20 | android: 'Double tap R on your keyboard to reload,\n' + 21 | 'Shake or press menu button for dev menu', 22 | }); 23 | 24 | export default class App extends Component { 25 | constructor(props) { 26 | super(props) 27 | // NativeModules.DynamicSplash.downloadSplash(); 28 | } 29 | componentDidMount() { 30 | // setTimeout(() => { 31 | // NativeModules.DynamicSplash.hide(); 32 | // }, 1000); 33 | } 34 | 35 | render() { 36 | return ( 37 | 38 | 39 | Welcome to React Native! 40 | 41 | 42 | To get started, edit App.js 43 | 44 | 45 | {instructions} 46 | 47 | 48 | ); 49 | } 50 | } 51 | 52 | const styles = StyleSheet.create({ 53 | container: { 54 | flex: 1, 55 | justifyContent: 'center', 56 | alignItems: 'center', 57 | backgroundColor: '#F5FCFF', 58 | }, 59 | welcome: { 60 | fontSize: 20, 61 | textAlign: 'center', 62 | margin: 10, 63 | }, 64 | instructions: { 65 | textAlign: 'center', 66 | color: '#333333', 67 | marginBottom: 5, 68 | }, 69 | }); 70 | -------------------------------------------------------------------------------- /example/android/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | example 4 | Project android created by Buildship. 5 | 6 | 7 | 8 | 9 | org.eclipse.buildship.core.gradleprojectbuilder 10 | 11 | 12 | 13 | 14 | 15 | org.eclipse.buildship.core.gradleprojectnature 16 | 17 | 18 | -------------------------------------------------------------------------------- /example/android/app/.classpath: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /example/android/app/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | app 4 | Project app created by Buildship. 5 | 6 | 7 | 8 | 9 | org.eclipse.jdt.core.javabuilder 10 | 11 | 12 | 13 | 14 | org.eclipse.buildship.core.gradleprojectbuilder 15 | 16 | 17 | 18 | 19 | 20 | org.eclipse.jdt.core.javanature 21 | org.eclipse.buildship.core.gradleprojectnature 22 | 23 | 24 | -------------------------------------------------------------------------------- /example/android/app/BUCK: -------------------------------------------------------------------------------- 1 | # To learn about Buck see [Docs](https://buckbuild.com/). 2 | # To run your application with Buck: 3 | # - install Buck 4 | # - `npm start` - to start the packager 5 | # - `cd android` 6 | # - `keytool -genkey -v -keystore keystores/debug.keystore -storepass android -alias androiddebugkey -keypass android -dname "CN=Android Debug,O=Android,C=US"` 7 | # - `./gradlew :app:copyDownloadableDepsToLibs` - make all Gradle compile dependencies available to Buck 8 | # - `buck install -r android/app` - compile, install and run application 9 | # 10 | 11 | lib_deps = [] 12 | 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 | ) 20 | 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 | ) 28 | 29 | android_library( 30 | name = "all-libs", 31 | exported_deps = lib_deps, 32 | ) 33 | 34 | android_library( 35 | name = "app-code", 36 | srcs = glob([ 37 | "src/main/java/**/*.java", 38 | ]), 39 | deps = [ 40 | ":all-libs", 41 | ":build_config", 42 | ":res", 43 | ], 44 | ) 45 | 46 | android_build_config( 47 | name = "build_config", 48 | package = "com.example", 49 | ) 50 | 51 | android_resource( 52 | name = "res", 53 | package = "com.example", 54 | res = "src/main/res", 55 | ) 56 | 57 | android_binary( 58 | name = "app", 59 | keystore = "//android/keystores:debug", 60 | manifest = "src/main/AndroidManifest.xml", 61 | package_type = "debug", 62 | deps = [ 63 | ":app-code", 64 | ], 65 | ) 66 | -------------------------------------------------------------------------------- /example/android/app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: "com.android.application" 2 | 3 | import com.android.build.OutputFile 4 | 5 | /** 6 | * The react.gradle file registers a task for each build variant (e.g. bundleDebugJsAndAssets 7 | * and bundleReleaseJsAndAssets). 8 | * These basically call `react-native bundle` with the correct arguments during the Android build 9 | * cycle. By default, bundleDebugJsAndAssets is skipped, as in debug/dev mode we prefer to load the 10 | * bundle directly from the development server. Below you can see all the possible configurations 11 | * and their defaults. If you decide to add a configuration block, make sure to add it before the 12 | * `apply from: "../../node_modules/react-native/react.gradle"` line. 13 | * 14 | * project.ext.react = [ 15 | * // the name of the generated asset file containing your JS bundle 16 | * bundleAssetName: "index.android.bundle", 17 | * 18 | * // the entry file for bundle generation 19 | * entryFile: "index.android.js", 20 | * 21 | * // whether to bundle JS and assets in debug mode 22 | * bundleInDebug: false, 23 | * 24 | * // whether to bundle JS and assets in release mode 25 | * bundleInRelease: true, 26 | * 27 | * // whether to bundle JS and assets in another build variant (if configured). 28 | * // See http://tools.android.com/tech-docs/new-build-system/user-guide#TOC-Build-Variants 29 | * // The configuration property can be in the following formats 30 | * // 'bundleIn${productFlavor}${buildType}' 31 | * // 'bundleIn${buildType}' 32 | * // bundleInFreeDebug: true, 33 | * // bundleInPaidRelease: true, 34 | * // bundleInBeta: true, 35 | * 36 | * // whether to disable dev mode in custom build variants (by default only disabled in release) 37 | * // for example: to disable dev mode in the staging build type (if configured) 38 | * devDisabledInStaging: true, 39 | * // The configuration property can be in the following formats 40 | * // 'devDisabledIn${productFlavor}${buildType}' 41 | * // 'devDisabledIn${buildType}' 42 | * 43 | * // the root of your project, i.e. where "package.json" lives 44 | * root: "../../", 45 | * 46 | * // where to put the JS bundle asset in debug mode 47 | * jsBundleDirDebug: "$buildDir/intermediates/assets/debug", 48 | * 49 | * // where to put the JS bundle asset in release mode 50 | * jsBundleDirRelease: "$buildDir/intermediates/assets/release", 51 | * 52 | * // where to put drawable resources / React Native assets, e.g. the ones you use via 53 | * // require('./image.png')), in debug mode 54 | * resourcesDirDebug: "$buildDir/intermediates/res/merged/debug", 55 | * 56 | * // where to put drawable resources / React Native assets, e.g. the ones you use via 57 | * // require('./image.png')), in release mode 58 | * resourcesDirRelease: "$buildDir/intermediates/res/merged/release", 59 | * 60 | * // by default the gradle tasks are skipped if none of the JS files or assets change; this means 61 | * // that we don't look at files in android/ or ios/ to determine whether the tasks are up to 62 | * // date; if you have any other folders that you want to ignore for performance reasons (gradle 63 | * // indexes the entire tree), add them here. Alternatively, if you have JS files in android/ 64 | * // for example, you might want to remove it from here. 65 | * inputExcludes: ["android/**", "ios/**"], 66 | * 67 | * // override which node gets called and with what additional arguments 68 | * nodeExecutableAndArgs: ["node"], 69 | * 70 | * // supply additional arguments to the packager 71 | * extraPackagerArgs: [] 72 | * ] 73 | */ 74 | 75 | project.ext.react = [ 76 | entryFile: "index.js" 77 | ] 78 | 79 | apply from: "../../node_modules/react-native/react.gradle" 80 | 81 | /** 82 | * Set this to true to create two separate APKs instead of one: 83 | * - An APK that only works on ARM devices 84 | * - An APK that only works on x86 devices 85 | * The advantage is the size of the APK is reduced by about 4MB. 86 | * Upload all the APKs to the Play Store and people will download 87 | * the correct one based on the CPU architecture of their device. 88 | */ 89 | def enableSeparateBuildPerCPUArchitecture = false 90 | 91 | /** 92 | * Run Proguard to shrink the Java bytecode in release builds. 93 | */ 94 | def enableProguardInReleaseBuilds = false 95 | 96 | android { 97 | compileSdkVersion 23 98 | buildToolsVersion "23.0.2" 99 | 100 | defaultConfig { 101 | applicationId "com.example" 102 | minSdkVersion 16 103 | targetSdkVersion 22 104 | versionCode 1 105 | versionName "1.0" 106 | ndk { 107 | abiFilters "armeabi-v7a", "x86" 108 | } 109 | } 110 | splits { 111 | abi { 112 | reset() 113 | enable enableSeparateBuildPerCPUArchitecture 114 | universalApk false // If true, also generate a universal APK 115 | include "armeabi-v7a", "x86" 116 | } 117 | } 118 | buildTypes { 119 | release { 120 | minifyEnabled enableProguardInReleaseBuilds 121 | proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro" 122 | } 123 | } 124 | // applicationVariants are e.g. debug, release 125 | applicationVariants.all { variant -> 126 | variant.outputs.each { output -> 127 | // 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] 130 | def abi = output.getFilter(OutputFile.ABI) 131 | if (abi != null) { // null for the universal-debug, universal-release variants 132 | output.versionCodeOverride = 133 | versionCodes.get(abi) * 1048576 + defaultConfig.versionCode 134 | } 135 | } 136 | } 137 | } 138 | 139 | dependencies { 140 | compile project(':react-native-dynamic-splash') 141 | 142 | compile fileTree(dir: "libs", include: ["*.jar"]) 143 | compile "com.android.support:appcompat-v7:23.0.1" 144 | compile "com.facebook.react:react-native:+" // From node_modules 145 | } 146 | 147 | // Run this once to be able to run the application with BUCK 148 | // puts all compile dependencies into folder libs for BUCK to use 149 | task copyDownloadableDepsToLibs(type: Copy) { 150 | from configurations.compile 151 | into 'libs' 152 | } 153 | -------------------------------------------------------------------------------- /example/android/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /usr/local/Cellar/android-sdk/24.3.3/tools/proguard/proguard-android.txt 4 | # You can edit the include path and order by changing the proguardFiles 5 | # directive in build.gradle. 6 | # 7 | # For more details, see 8 | # http://developer.android.com/guide/developing/tools/proguard.html 9 | 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 ; } 47 | -keepclassmembers class * { @com.facebook.react.uimanager.UIProp ; } 48 | -keepclassmembers class * { @com.facebook.react.uimanager.annotations.ReactProp ; } 49 | -keepclassmembers class * { @com.facebook.react.uimanager.annotations.ReactPropGroup ; } 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.** 71 | -------------------------------------------------------------------------------- /example/android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | 7 | 13 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /example/android/app/src/main/java/com/example/MainActivity.java: -------------------------------------------------------------------------------- 1 | package com.example; 2 | 3 | import android.os.Bundle; 4 | 5 | import com.facebook.react.ReactActivity; 6 | import com.taumu.rnDynamicSplash.DynamicSplash; 7 | import com.taumu.rnDynamicSplash.utils.Config; 8 | 9 | public class MainActivity extends ReactActivity { 10 | 11 | /** 12 | * Returns the name of the main component registered from JavaScript. 13 | * This is used to schedule rendering of the component. 14 | */ 15 | @Override 16 | protected String getMainComponentName() { 17 | return "example"; 18 | } 19 | 20 | @Override 21 | protected void onCreate(Bundle savedInstanceState) { 22 | Config splashConfig = new Config(); 23 | splashConfig.setImageUrl("http://chuantu.biz/t6/315/1526808193x-1404792987.png"); 24 | 25 | splashConfig.setAutoHide(true); 26 | // splashConfig.setAutoHideTime(2000); 27 | // splashConfig.setLayoutResID(R.layout.custom_splash_dynamic); 28 | // splashConfig.setThemeResId(R.style.Custom_Splash_Theme); 29 | // splashConfig.setAutoDownload(false); 30 | // splashConfig.setSplashSavePath("/customSplashPath/"); 31 | // splashConfig.setDynamicShow(false); 32 | new DynamicSplash(this, splashConfig); 33 | super.onCreate(savedInstanceState); 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /example/android/app/src/main/java/com/example/MainApplication.java: -------------------------------------------------------------------------------- 1 | package com.example; 2 | 3 | import android.app.Application; 4 | 5 | import com.facebook.react.ReactApplication; 6 | import com.facebook.react.ReactNativeHost; 7 | import com.facebook.react.ReactPackage; 8 | import com.facebook.react.shell.MainReactPackage; 9 | import com.facebook.soloader.SoLoader; 10 | import com.taumu.rnDynamicSplash.DynamicSplashReactPackage; 11 | 12 | import java.util.Arrays; 13 | import java.util.List; 14 | 15 | public class MainApplication extends Application implements ReactApplication { 16 | 17 | private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) { 18 | @Override 19 | public boolean getUseDeveloperSupport() { 20 | return BuildConfig.DEBUG; 21 | } 22 | 23 | @Override 24 | protected List getPackages() { 25 | return Arrays.asList( 26 | new MainReactPackage(), 27 | new DynamicSplashReactPackage() 28 | ); 29 | } 30 | 31 | @Override 32 | protected String getJSMainModuleName() { 33 | return "index"; 34 | } 35 | }; 36 | 37 | @Override 38 | public ReactNativeHost getReactNativeHost() { 39 | return mReactNativeHost; 40 | } 41 | 42 | @Override 43 | public void onCreate() { 44 | super.onCreate(); 45 | SoLoader.init(this, /* native exopackage */ false); 46 | } 47 | } 48 | -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TaumuLu/react-native-dynamic-splash/a3d368126f8ab1152c29ec0d65a311a8ee8b5593/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TaumuLu/react-native-dynamic-splash/a3d368126f8ab1152c29ec0d65a311a8ee8b5593/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TaumuLu/react-native-dynamic-splash/a3d368126f8ab1152c29ec0d65a311a8ee8b5593/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TaumuLu/react-native-dynamic-splash/a3d368126f8ab1152c29ec0d65a311a8ee8b5593/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | example 3 | 4 | -------------------------------------------------------------------------------- /example/android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | 8 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /example/android/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | 3 | buildscript { 4 | repositories { 5 | jcenter() 6 | } 7 | dependencies { 8 | classpath 'com.android.tools.build:gradle:2.2.3' 9 | 10 | // NOTE: Do not place your application dependencies here; they belong 11 | // in the individual module build.gradle files 12 | } 13 | } 14 | 15 | allprojects { 16 | repositories { 17 | mavenLocal() 18 | jcenter() 19 | maven { 20 | // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm 21 | url "$rootDir/../node_modules/react-native/android" 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /example/android/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | 3 | # IDE (e.g. Android Studio) users: 4 | # Gradle settings configured through the IDE *will override* 5 | # any settings specified in this file. 6 | 7 | # For more details on how to configure your build environment visit 8 | # http://www.gradle.org/docs/current/userguide/build_environment.html 9 | 10 | # Specifies the JVM arguments used for the daemon process. 11 | # The setting is particularly useful for tweaking memory settings. 12 | # Default value: -Xmx10248m -XX:MaxPermSize=256m 13 | # org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 14 | 15 | # When configured, Gradle will run in incubating parallel mode. 16 | # This option should only be used with decoupled projects. More details, visit 17 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 18 | # org.gradle.parallel=true 19 | 20 | android.useDeprecatedNdk=true 21 | -------------------------------------------------------------------------------- /example/android/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TaumuLu/react-native-dynamic-splash/a3d368126f8ab1152c29ec0d65a311a8ee8b5593/example/android/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /example/android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | zipStoreBase=GRADLE_USER_HOME 4 | zipStorePath=wrapper/dists 5 | distributionUrl=https\://services.gradle.org/distributions/gradle-2.14.1-all.zip 6 | -------------------------------------------------------------------------------- /example/android/gradlew: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | ############################################################################## 4 | ## 5 | ## Gradle start up script for UN*X 6 | ## 7 | ############################################################################## 8 | 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="" 11 | 12 | APP_NAME="Gradle" 13 | APP_BASE_NAME=`basename "$0"` 14 | 15 | # Use the maximum available, or set MAX_FD != -1 to use that value. 16 | MAX_FD="maximum" 17 | 18 | warn ( ) { 19 | echo "$*" 20 | } 21 | 22 | die ( ) { 23 | echo 24 | echo "$*" 25 | echo 26 | exit 1 27 | } 28 | 29 | # OS specific support (must be 'true' or 'false'). 30 | cygwin=false 31 | msys=false 32 | darwin=false 33 | case "`uname`" in 34 | CYGWIN* ) 35 | cygwin=true 36 | ;; 37 | Darwin* ) 38 | darwin=true 39 | ;; 40 | MINGW* ) 41 | msys=true 42 | ;; 43 | esac 44 | 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 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar 69 | 70 | # Determine the Java command to use to start the JVM. 71 | if [ -n "$JAVA_HOME" ] ; then 72 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then 73 | # IBM's JDK on AIX uses strange locations for the executables 74 | JAVACMD="$JAVA_HOME/jre/sh/java" 75 | else 76 | JAVACMD="$JAVA_HOME/bin/java" 77 | fi 78 | if [ ! -x "$JAVACMD" ] ; then 79 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME 80 | 81 | Please set the JAVA_HOME variable in your environment to match the 82 | location of your Java installation." 83 | fi 84 | else 85 | JAVACMD="java" 86 | which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 87 | 88 | Please set the JAVA_HOME variable in your environment to match the 89 | location of your Java installation." 90 | fi 91 | 92 | # Increase the maximum file descriptors if we can. 93 | if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then 94 | MAX_FD_LIMIT=`ulimit -H -n` 95 | if [ $? -eq 0 ] ; then 96 | if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then 97 | MAX_FD="$MAX_FD_LIMIT" 98 | fi 99 | ulimit -n $MAX_FD 100 | if [ $? -ne 0 ] ; then 101 | warn "Could not set maximum file descriptor limit: $MAX_FD" 102 | fi 103 | else 104 | warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT" 105 | fi 106 | fi 107 | 108 | # For Darwin, add options to specify how the application appears in the dock 109 | if $darwin; then 110 | GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\"" 111 | fi 112 | 113 | # For Cygwin, switch paths to Windows format before running java 114 | if $cygwin ; then 115 | APP_HOME=`cygpath --path --mixed "$APP_HOME"` 116 | CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` 117 | 118 | # We build the pattern for arguments to be converted via cygpath 119 | ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null` 120 | SEP="" 121 | for dir in $ROOTDIRSRAW ; do 122 | ROOTDIRS="$ROOTDIRS$SEP$dir" 123 | SEP="|" 124 | done 125 | OURCYGPATTERN="(^($ROOTDIRS))" 126 | # Add a user-defined pattern to the cygpath arguments 127 | if [ "$GRADLE_CYGPATTERN" != "" ] ; then 128 | OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)" 129 | fi 130 | # Now convert the arguments - kludge to limit ourselves to /bin/sh 131 | i=0 132 | for arg in "$@" ; do 133 | CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -` 134 | CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option 135 | 136 | if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition 137 | eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"` 138 | else 139 | eval `echo args$i`="\"$arg\"" 140 | fi 141 | i=$((i+1)) 142 | done 143 | case $i in 144 | (0) set -- ;; 145 | (1) set -- "$args0" ;; 146 | (2) set -- "$args0" "$args1" ;; 147 | (3) set -- "$args0" "$args1" "$args2" ;; 148 | (4) set -- "$args0" "$args1" "$args2" "$args3" ;; 149 | (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;; 150 | (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;; 151 | (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;; 152 | (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;; 153 | (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;; 154 | esac 155 | fi 156 | 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=("$@") 160 | } 161 | eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS 162 | JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME" 163 | 164 | exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@" 165 | -------------------------------------------------------------------------------- /example/android/gradlew.bat: -------------------------------------------------------------------------------- 1 | @if "%DEBUG%" == "" @echo off 2 | @rem ########################################################################## 3 | @rem 4 | @rem Gradle startup script for Windows 5 | @rem 6 | @rem ########################################################################## 7 | 8 | @rem Set local scope for the variables with windows NT shell 9 | if "%OS%"=="Windows_NT" setlocal 10 | 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 | set DIRNAME=%~dp0 15 | if "%DIRNAME%" == "" set DIRNAME=. 16 | set APP_BASE_NAME=%~n0 17 | set APP_HOME=%DIRNAME% 18 | 19 | @rem Find java.exe 20 | if defined JAVA_HOME goto findJavaFromJavaHome 21 | 22 | set JAVA_EXE=java.exe 23 | %JAVA_EXE% -version >NUL 2>&1 24 | if "%ERRORLEVEL%" == "0" goto init 25 | 26 | echo. 27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 28 | echo. 29 | echo Please set the JAVA_HOME variable in your environment to match the 30 | echo location of your Java installation. 31 | 32 | goto fail 33 | 34 | :findJavaFromJavaHome 35 | set JAVA_HOME=%JAVA_HOME:"=% 36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe 37 | 38 | if exist "%JAVA_EXE%" goto init 39 | 40 | echo. 41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 42 | echo. 43 | echo Please set the JAVA_HOME variable in your environment to match the 44 | echo location of your Java installation. 45 | 46 | goto fail 47 | 48 | :init 49 | @rem Get command-line arguments, handling Windowz variants 50 | 51 | if not "%OS%" == "Windows_NT" goto win9xME_args 52 | if "%@eval[2+2]" == "4" goto 4NT_args 53 | 54 | :win9xME_args 55 | @rem Slurp the command line arguments. 56 | set CMD_LINE_ARGS= 57 | set _SKIP=2 58 | 59 | :win9xME_args_slurp 60 | if "x%~1" == "x" goto execute 61 | 62 | 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 | 69 | :execute 70 | @rem Setup the command line 71 | 72 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar 73 | 74 | @rem Execute Gradle 75 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% 76 | 77 | :end 78 | @rem End local scope for the variables with windows NT shell 79 | if "%ERRORLEVEL%"=="0" goto mainEnd 80 | 81 | :fail 82 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of 83 | rem the _cmd.exe /c_ return code! 84 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 85 | exit /b 1 86 | 87 | :mainEnd 88 | if "%OS%"=="Windows_NT" endlocal 89 | 90 | :omega 91 | -------------------------------------------------------------------------------- /example/android/keystores/BUCK: -------------------------------------------------------------------------------- 1 | keystore( 2 | name = "debug", 3 | properties = "debug.keystore.properties", 4 | store = "debug.keystore", 5 | visibility = [ 6 | "PUBLIC", 7 | ], 8 | ) 9 | -------------------------------------------------------------------------------- /example/android/keystores/debug.keystore.properties: -------------------------------------------------------------------------------- 1 | key.store=debug.keystore 2 | key.alias=androiddebugkey 3 | key.store.password=android 4 | key.alias.password=android 5 | -------------------------------------------------------------------------------- /example/android/settings.gradle: -------------------------------------------------------------------------------- 1 | rootProject.name = 'example' 2 | 3 | include ':react-native-dynamic-splash' 4 | project(':react-native-dynamic-splash').projectDir = new File(rootProject.projectDir, '../../android') 5 | 6 | include ':app' 7 | -------------------------------------------------------------------------------- /example/app.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "example", 3 | "displayName": "example" 4 | } -------------------------------------------------------------------------------- /example/index.js: -------------------------------------------------------------------------------- 1 | import { AppRegistry } from 'react-native'; 2 | import App from './App'; 3 | 4 | AppRegistry.registerComponent('example', () => App); 5 | -------------------------------------------------------------------------------- /example/ios/example-tvOS/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | APPL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | LSRequiresIPhoneOS 24 | 25 | UILaunchStoryboardName 26 | LaunchScreen 27 | UIRequiredDeviceCapabilities 28 | 29 | armv7 30 | 31 | UISupportedInterfaceOrientations 32 | 33 | UIInterfaceOrientationPortrait 34 | UIInterfaceOrientationLandscapeLeft 35 | UIInterfaceOrientationLandscapeRight 36 | 37 | UIViewControllerBasedStatusBarAppearance 38 | 39 | NSLocationWhenInUseUsageDescription 40 | 41 | NSAppTransportSecurity 42 | 43 | 44 | NSExceptionDomains 45 | 46 | localhost 47 | 48 | NSExceptionAllowsInsecureHTTPLoads 49 | 50 | 51 | 52 | 53 | 54 | 55 | -------------------------------------------------------------------------------- /example/ios/example-tvOSTests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | BNDL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | 24 | 25 | -------------------------------------------------------------------------------- /example/ios/example.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 46; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 00C302E51ABCBA2D00DB3ED1 /* libRCTActionSheet.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302AC1ABCB8CE00DB3ED1 /* libRCTActionSheet.a */; }; 11 | 00C302E71ABCBA2D00DB3ED1 /* libRCTGeolocation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302BA1ABCB90400DB3ED1 /* libRCTGeolocation.a */; }; 12 | 00C302E81ABCBA2D00DB3ED1 /* libRCTImage.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302C01ABCB91800DB3ED1 /* libRCTImage.a */; }; 13 | 00C302E91ABCBA2D00DB3ED1 /* libRCTNetwork.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302DC1ABCB9D200DB3ED1 /* libRCTNetwork.a */; }; 14 | 00C302EA1ABCBA2D00DB3ED1 /* libRCTVibration.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302E41ABCB9EE00DB3ED1 /* libRCTVibration.a */; }; 15 | 00E356F31AD99517003FC87E /* exampleTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 00E356F21AD99517003FC87E /* exampleTests.m */; }; 16 | 133E29F31AD74F7200F7D852 /* libRCTLinking.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 78C398B91ACF4ADC00677621 /* libRCTLinking.a */; }; 17 | 139105C61AF99C1200B5F7CC /* libRCTSettings.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 139105C11AF99BAD00B5F7CC /* libRCTSettings.a */; }; 18 | 139FDEF61B0652A700C62182 /* libRCTWebSocket.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 139FDEF41B06529B00C62182 /* libRCTWebSocket.a */; }; 19 | 13B07FBC1A68108700A75B9A /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.m */; }; 20 | 13B07FBD1A68108700A75B9A /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB11A68108700A75B9A /* LaunchScreen.xib */; }; 21 | 13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; }; 22 | 140ED2AC1D01E1AD002B40FF /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 146834041AC3E56700842450 /* libReact.a */; }; 23 | 146834051AC3E58100842450 /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 146834041AC3E56700842450 /* libReact.a */; }; 24 | 2D02E4BC1E0B4A80006451C7 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.m */; }; 25 | 2D02E4BF1E0B4AB3006451C7 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; }; 26 | 2D02E4C21E0B4AEC006451C7 /* libRCTAnimation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5E9157351DD0AC6500FF2AA8 /* libRCTAnimation.a */; }; 27 | 2D02E4C31E0B4AEC006451C7 /* libRCTImage-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E841DF850E9000B6D8A /* libRCTImage-tvOS.a */; }; 28 | 2D02E4C41E0B4AEC006451C7 /* libRCTLinking-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E881DF850E9000B6D8A /* libRCTLinking-tvOS.a */; }; 29 | 2D02E4C51E0B4AEC006451C7 /* libRCTNetwork-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E8C1DF850E9000B6D8A /* libRCTNetwork-tvOS.a */; }; 30 | 2D02E4C61E0B4AEC006451C7 /* libRCTSettings-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E901DF850E9000B6D8A /* libRCTSettings-tvOS.a */; }; 31 | 2D02E4C71E0B4AEC006451C7 /* libRCTText-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E941DF850E9000B6D8A /* libRCTText-tvOS.a */; }; 32 | 2D02E4C81E0B4AEC006451C7 /* libRCTWebSocket-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E991DF850E9000B6D8A /* libRCTWebSocket-tvOS.a */; }; 33 | 2D16E6881FA4F8E400B85C8A /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 2D16E6891FA4F8E400B85C8A /* libReact.a */; }; 34 | 2DCD954D1E0B4F2C00145EB5 /* exampleTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 00E356F21AD99517003FC87E /* exampleTests.m */; }; 35 | 2DF0FFEE2056DD460020B375 /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3EA31DF850E9000B6D8A /* libReact.a */; }; 36 | 5E9157361DD0AC6A00FF2AA8 /* libRCTAnimation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5E9157331DD0AC6500FF2AA8 /* libRCTAnimation.a */; }; 37 | 6EADEE4920C78FCA00D10395 /* libRNDynamicSplash.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 6EADEE4820C78F8500D10395 /* libRNDynamicSplash.a */; }; 38 | 6EADEE4B20C7C0D800D10395 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 6EADEE4A20C7C0D800D10395 /* Images.xcassets */; }; 39 | 832341BD1AAA6AB300B99B32 /* libRCTText.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 832341B51AAA6A8300B99B32 /* libRCTText.a */; }; 40 | ADBDB9381DFEBF1600ED6528 /* libRCTBlob.a in Frameworks */ = {isa = PBXBuildFile; fileRef = ADBDB9271DFEBF0700ED6528 /* libRCTBlob.a */; }; 41 | /* End PBXBuildFile section */ 42 | 43 | /* Begin PBXContainerItemProxy section */ 44 | 00C302AB1ABCB8CE00DB3ED1 /* PBXContainerItemProxy */ = { 45 | isa = PBXContainerItemProxy; 46 | containerPortal = 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */; 47 | proxyType = 2; 48 | remoteGlobalIDString = 134814201AA4EA6300B7C361; 49 | remoteInfo = RCTActionSheet; 50 | }; 51 | 00C302B91ABCB90400DB3ED1 /* PBXContainerItemProxy */ = { 52 | isa = PBXContainerItemProxy; 53 | containerPortal = 00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */; 54 | proxyType = 2; 55 | remoteGlobalIDString = 134814201AA4EA6300B7C361; 56 | remoteInfo = RCTGeolocation; 57 | }; 58 | 00C302BF1ABCB91800DB3ED1 /* PBXContainerItemProxy */ = { 59 | isa = PBXContainerItemProxy; 60 | containerPortal = 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */; 61 | proxyType = 2; 62 | remoteGlobalIDString = 58B5115D1A9E6B3D00147676; 63 | remoteInfo = RCTImage; 64 | }; 65 | 00C302DB1ABCB9D200DB3ED1 /* PBXContainerItemProxy */ = { 66 | isa = PBXContainerItemProxy; 67 | containerPortal = 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */; 68 | proxyType = 2; 69 | remoteGlobalIDString = 58B511DB1A9E6C8500147676; 70 | remoteInfo = RCTNetwork; 71 | }; 72 | 00C302E31ABCB9EE00DB3ED1 /* PBXContainerItemProxy */ = { 73 | isa = PBXContainerItemProxy; 74 | containerPortal = 00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */; 75 | proxyType = 2; 76 | remoteGlobalIDString = 832C81801AAF6DEF007FA2F7; 77 | remoteInfo = RCTVibration; 78 | }; 79 | 00E356F41AD99517003FC87E /* PBXContainerItemProxy */ = { 80 | isa = PBXContainerItemProxy; 81 | containerPortal = 83CBB9F71A601CBA00E9B192 /* Project object */; 82 | proxyType = 1; 83 | remoteGlobalIDString = 13B07F861A680F5B00A75B9A; 84 | remoteInfo = example; 85 | }; 86 | 139105C01AF99BAD00B5F7CC /* PBXContainerItemProxy */ = { 87 | isa = PBXContainerItemProxy; 88 | containerPortal = 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */; 89 | proxyType = 2; 90 | remoteGlobalIDString = 134814201AA4EA6300B7C361; 91 | remoteInfo = RCTSettings; 92 | }; 93 | 139FDEF31B06529B00C62182 /* PBXContainerItemProxy */ = { 94 | isa = PBXContainerItemProxy; 95 | containerPortal = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */; 96 | proxyType = 2; 97 | remoteGlobalIDString = 3C86DF461ADF2C930047B81A; 98 | remoteInfo = RCTWebSocket; 99 | }; 100 | 146834031AC3E56700842450 /* PBXContainerItemProxy */ = { 101 | isa = PBXContainerItemProxy; 102 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 103 | proxyType = 2; 104 | remoteGlobalIDString = 83CBBA2E1A601D0E00E9B192; 105 | remoteInfo = React; 106 | }; 107 | 2D02E4911E0B4A5D006451C7 /* PBXContainerItemProxy */ = { 108 | isa = PBXContainerItemProxy; 109 | containerPortal = 83CBB9F71A601CBA00E9B192 /* Project object */; 110 | proxyType = 1; 111 | remoteGlobalIDString = 2D02E47A1E0B4A5D006451C7; 112 | remoteInfo = "example-tvOS"; 113 | }; 114 | 2D16E6711FA4F8DC00B85C8A /* PBXContainerItemProxy */ = { 115 | isa = PBXContainerItemProxy; 116 | containerPortal = ADBDB91F1DFEBF0600ED6528 /* RCTBlob.xcodeproj */; 117 | proxyType = 2; 118 | remoteGlobalIDString = ADD01A681E09402E00F6D226; 119 | remoteInfo = "RCTBlob-tvOS"; 120 | }; 121 | 2D16E6831FA4F8DC00B85C8A /* PBXContainerItemProxy */ = { 122 | isa = PBXContainerItemProxy; 123 | containerPortal = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */; 124 | proxyType = 2; 125 | remoteGlobalIDString = 3DBE0D001F3B181A0099AA32; 126 | remoteInfo = fishhook; 127 | }; 128 | 2D16E6851FA4F8DC00B85C8A /* PBXContainerItemProxy */ = { 129 | isa = PBXContainerItemProxy; 130 | containerPortal = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */; 131 | proxyType = 2; 132 | remoteGlobalIDString = 3DBE0D0D1F3B181C0099AA32; 133 | remoteInfo = "fishhook-tvOS"; 134 | }; 135 | 2DF0FFDE2056DD460020B375 /* PBXContainerItemProxy */ = { 136 | isa = PBXContainerItemProxy; 137 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 138 | proxyType = 2; 139 | remoteGlobalIDString = EBF21BDC1FC498900052F4D5; 140 | remoteInfo = jsinspector; 141 | }; 142 | 2DF0FFE02056DD460020B375 /* PBXContainerItemProxy */ = { 143 | isa = PBXContainerItemProxy; 144 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 145 | proxyType = 2; 146 | remoteGlobalIDString = EBF21BFA1FC4989A0052F4D5; 147 | remoteInfo = "jsinspector-tvOS"; 148 | }; 149 | 2DF0FFE22056DD460020B375 /* PBXContainerItemProxy */ = { 150 | isa = PBXContainerItemProxy; 151 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 152 | proxyType = 2; 153 | remoteGlobalIDString = 139D7ECE1E25DB7D00323FB7; 154 | remoteInfo = "third-party"; 155 | }; 156 | 2DF0FFE42056DD460020B375 /* PBXContainerItemProxy */ = { 157 | isa = PBXContainerItemProxy; 158 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 159 | proxyType = 2; 160 | remoteGlobalIDString = 3D383D3C1EBD27B6005632C8; 161 | remoteInfo = "third-party-tvOS"; 162 | }; 163 | 2DF0FFE62056DD460020B375 /* PBXContainerItemProxy */ = { 164 | isa = PBXContainerItemProxy; 165 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 166 | proxyType = 2; 167 | remoteGlobalIDString = 139D7E881E25C6D100323FB7; 168 | remoteInfo = "double-conversion"; 169 | }; 170 | 2DF0FFE82056DD460020B375 /* PBXContainerItemProxy */ = { 171 | isa = PBXContainerItemProxy; 172 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 173 | proxyType = 2; 174 | remoteGlobalIDString = 3D383D621EBD27B9005632C8; 175 | remoteInfo = "double-conversion-tvOS"; 176 | }; 177 | 2DF0FFEA2056DD460020B375 /* PBXContainerItemProxy */ = { 178 | isa = PBXContainerItemProxy; 179 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 180 | proxyType = 2; 181 | remoteGlobalIDString = 9936F3131F5F2E4B0010BF04; 182 | remoteInfo = privatedata; 183 | }; 184 | 2DF0FFEC2056DD460020B375 /* PBXContainerItemProxy */ = { 185 | isa = PBXContainerItemProxy; 186 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 187 | proxyType = 2; 188 | remoteGlobalIDString = 9936F32F1F5F2E5B0010BF04; 189 | remoteInfo = "privatedata-tvOS"; 190 | }; 191 | 3DAD3E831DF850E9000B6D8A /* PBXContainerItemProxy */ = { 192 | isa = PBXContainerItemProxy; 193 | containerPortal = 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */; 194 | proxyType = 2; 195 | remoteGlobalIDString = 2D2A283A1D9B042B00D4039D; 196 | remoteInfo = "RCTImage-tvOS"; 197 | }; 198 | 3DAD3E871DF850E9000B6D8A /* PBXContainerItemProxy */ = { 199 | isa = PBXContainerItemProxy; 200 | containerPortal = 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */; 201 | proxyType = 2; 202 | remoteGlobalIDString = 2D2A28471D9B043800D4039D; 203 | remoteInfo = "RCTLinking-tvOS"; 204 | }; 205 | 3DAD3E8B1DF850E9000B6D8A /* PBXContainerItemProxy */ = { 206 | isa = PBXContainerItemProxy; 207 | containerPortal = 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */; 208 | proxyType = 2; 209 | remoteGlobalIDString = 2D2A28541D9B044C00D4039D; 210 | remoteInfo = "RCTNetwork-tvOS"; 211 | }; 212 | 3DAD3E8F1DF850E9000B6D8A /* PBXContainerItemProxy */ = { 213 | isa = PBXContainerItemProxy; 214 | containerPortal = 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */; 215 | proxyType = 2; 216 | remoteGlobalIDString = 2D2A28611D9B046600D4039D; 217 | remoteInfo = "RCTSettings-tvOS"; 218 | }; 219 | 3DAD3E931DF850E9000B6D8A /* PBXContainerItemProxy */ = { 220 | isa = PBXContainerItemProxy; 221 | containerPortal = 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */; 222 | proxyType = 2; 223 | remoteGlobalIDString = 2D2A287B1D9B048500D4039D; 224 | remoteInfo = "RCTText-tvOS"; 225 | }; 226 | 3DAD3E981DF850E9000B6D8A /* PBXContainerItemProxy */ = { 227 | isa = PBXContainerItemProxy; 228 | containerPortal = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */; 229 | proxyType = 2; 230 | remoteGlobalIDString = 2D2A28881D9B049200D4039D; 231 | remoteInfo = "RCTWebSocket-tvOS"; 232 | }; 233 | 3DAD3EA21DF850E9000B6D8A /* PBXContainerItemProxy */ = { 234 | isa = PBXContainerItemProxy; 235 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 236 | proxyType = 2; 237 | remoteGlobalIDString = 2D2A28131D9B038B00D4039D; 238 | remoteInfo = "React-tvOS"; 239 | }; 240 | 3DAD3EA41DF850E9000B6D8A /* PBXContainerItemProxy */ = { 241 | isa = PBXContainerItemProxy; 242 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 243 | proxyType = 2; 244 | remoteGlobalIDString = 3D3C059A1DE3340900C268FA; 245 | remoteInfo = yoga; 246 | }; 247 | 3DAD3EA61DF850E9000B6D8A /* PBXContainerItemProxy */ = { 248 | isa = PBXContainerItemProxy; 249 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 250 | proxyType = 2; 251 | remoteGlobalIDString = 3D3C06751DE3340C00C268FA; 252 | remoteInfo = "yoga-tvOS"; 253 | }; 254 | 3DAD3EA81DF850E9000B6D8A /* PBXContainerItemProxy */ = { 255 | isa = PBXContainerItemProxy; 256 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 257 | proxyType = 2; 258 | remoteGlobalIDString = 3D3CD9251DE5FBEC00167DC4; 259 | remoteInfo = cxxreact; 260 | }; 261 | 3DAD3EAA1DF850E9000B6D8A /* PBXContainerItemProxy */ = { 262 | isa = PBXContainerItemProxy; 263 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 264 | proxyType = 2; 265 | remoteGlobalIDString = 3D3CD9321DE5FBEE00167DC4; 266 | remoteInfo = "cxxreact-tvOS"; 267 | }; 268 | 3DAD3EAC1DF850E9000B6D8A /* PBXContainerItemProxy */ = { 269 | isa = PBXContainerItemProxy; 270 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 271 | proxyType = 2; 272 | remoteGlobalIDString = 3D3CD90B1DE5FBD600167DC4; 273 | remoteInfo = jschelpers; 274 | }; 275 | 3DAD3EAE1DF850E9000B6D8A /* PBXContainerItemProxy */ = { 276 | isa = PBXContainerItemProxy; 277 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */; 278 | proxyType = 2; 279 | remoteGlobalIDString = 3D3CD9181DE5FBD800167DC4; 280 | remoteInfo = "jschelpers-tvOS"; 281 | }; 282 | 5E9157321DD0AC6500FF2AA8 /* PBXContainerItemProxy */ = { 283 | isa = PBXContainerItemProxy; 284 | containerPortal = 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */; 285 | proxyType = 2; 286 | remoteGlobalIDString = 134814201AA4EA6300B7C361; 287 | remoteInfo = RCTAnimation; 288 | }; 289 | 5E9157341DD0AC6500FF2AA8 /* PBXContainerItemProxy */ = { 290 | isa = PBXContainerItemProxy; 291 | containerPortal = 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */; 292 | proxyType = 2; 293 | remoteGlobalIDString = 2D2A28201D9B03D100D4039D; 294 | remoteInfo = "RCTAnimation-tvOS"; 295 | }; 296 | 6EADEE4720C78F8500D10395 /* PBXContainerItemProxy */ = { 297 | isa = PBXContainerItemProxy; 298 | containerPortal = 6EADEE4320C78F8500D10395 /* RNDynamicSplash.xcodeproj */; 299 | proxyType = 2; 300 | remoteGlobalIDString = 6EF65A1C20B17BCA0076D1FA; 301 | remoteInfo = RNDynamicSplash; 302 | }; 303 | 78C398B81ACF4ADC00677621 /* PBXContainerItemProxy */ = { 304 | isa = PBXContainerItemProxy; 305 | containerPortal = 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */; 306 | proxyType = 2; 307 | remoteGlobalIDString = 134814201AA4EA6300B7C361; 308 | remoteInfo = RCTLinking; 309 | }; 310 | 832341B41AAA6A8300B99B32 /* PBXContainerItemProxy */ = { 311 | isa = PBXContainerItemProxy; 312 | containerPortal = 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */; 313 | proxyType = 2; 314 | remoteGlobalIDString = 58B5119B1A9E6C1200147676; 315 | remoteInfo = RCTText; 316 | }; 317 | ADBDB9261DFEBF0700ED6528 /* PBXContainerItemProxy */ = { 318 | isa = PBXContainerItemProxy; 319 | containerPortal = ADBDB91F1DFEBF0600ED6528 /* RCTBlob.xcodeproj */; 320 | proxyType = 2; 321 | remoteGlobalIDString = 358F4ED71D1E81A9004DF814; 322 | remoteInfo = RCTBlob; 323 | }; 324 | /* End PBXContainerItemProxy section */ 325 | 326 | /* Begin PBXFileReference section */ 327 | 008F07F21AC5B25A0029DE68 /* main.jsbundle */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = main.jsbundle; sourceTree = ""; }; 328 | 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTActionSheet.xcodeproj; path = "../node_modules/react-native/Libraries/ActionSheetIOS/RCTActionSheet.xcodeproj"; sourceTree = ""; }; 329 | 00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTGeolocation.xcodeproj; path = "../node_modules/react-native/Libraries/Geolocation/RCTGeolocation.xcodeproj"; sourceTree = ""; }; 330 | 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTImage.xcodeproj; path = "../node_modules/react-native/Libraries/Image/RCTImage.xcodeproj"; sourceTree = ""; }; 331 | 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTNetwork.xcodeproj; path = "../node_modules/react-native/Libraries/Network/RCTNetwork.xcodeproj"; sourceTree = ""; }; 332 | 00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTVibration.xcodeproj; path = "../node_modules/react-native/Libraries/Vibration/RCTVibration.xcodeproj"; sourceTree = ""; }; 333 | 00E356EE1AD99517003FC87E /* exampleTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = exampleTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 334 | 00E356F11AD99517003FC87E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 335 | 00E356F21AD99517003FC87E /* exampleTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = exampleTests.m; sourceTree = ""; }; 336 | 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTSettings.xcodeproj; path = "../node_modules/react-native/Libraries/Settings/RCTSettings.xcodeproj"; sourceTree = ""; }; 337 | 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTWebSocket.xcodeproj; path = "../node_modules/react-native/Libraries/WebSocket/RCTWebSocket.xcodeproj"; sourceTree = ""; }; 338 | 13B07F961A680F5B00A75B9A /* example.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = example.app; sourceTree = BUILT_PRODUCTS_DIR; }; 339 | 13B07FAF1A68108700A75B9A /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = example/AppDelegate.h; sourceTree = ""; }; 340 | 13B07FB01A68108700A75B9A /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = AppDelegate.m; path = example/AppDelegate.m; sourceTree = ""; }; 341 | 13B07FB21A68108700A75B9A /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/LaunchScreen.xib; sourceTree = ""; }; 342 | 13B07FB61A68108700A75B9A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = example/Info.plist; sourceTree = ""; }; 343 | 13B07FB71A68108700A75B9A /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = example/main.m; sourceTree = ""; }; 344 | 146833FF1AC3E56700842450 /* React.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = React.xcodeproj; path = "../node_modules/react-native/React/React.xcodeproj"; sourceTree = ""; }; 345 | 2D02E47B1E0B4A5D006451C7 /* example-tvOS.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "example-tvOS.app"; sourceTree = BUILT_PRODUCTS_DIR; }; 346 | 2D02E4901E0B4A5D006451C7 /* example-tvOSTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "example-tvOSTests.xctest"; sourceTree = BUILT_PRODUCTS_DIR; }; 347 | 2D16E6891FA4F8E400B85C8A /* libReact.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; path = libReact.a; sourceTree = BUILT_PRODUCTS_DIR; }; 348 | 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTAnimation.xcodeproj; path = "../node_modules/react-native/Libraries/NativeAnimation/RCTAnimation.xcodeproj"; sourceTree = ""; }; 349 | 6EADEE4320C78F8500D10395 /* RNDynamicSplash.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RNDynamicSplash.xcodeproj; path = ../../ios/RNDynamicSplash.xcodeproj; sourceTree = ""; }; 350 | 6EADEE4A20C7C0D800D10395 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = example/Images.xcassets; sourceTree = ""; }; 351 | 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTLinking.xcodeproj; path = "../node_modules/react-native/Libraries/LinkingIOS/RCTLinking.xcodeproj"; sourceTree = ""; }; 352 | 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTText.xcodeproj; path = "../node_modules/react-native/Libraries/Text/RCTText.xcodeproj"; sourceTree = ""; }; 353 | ADBDB91F1DFEBF0600ED6528 /* RCTBlob.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTBlob.xcodeproj; path = "../node_modules/react-native/Libraries/Blob/RCTBlob.xcodeproj"; sourceTree = ""; }; 354 | /* End PBXFileReference section */ 355 | 356 | /* Begin PBXFrameworksBuildPhase section */ 357 | 00E356EB1AD99517003FC87E /* Frameworks */ = { 358 | isa = PBXFrameworksBuildPhase; 359 | buildActionMask = 2147483647; 360 | files = ( 361 | 140ED2AC1D01E1AD002B40FF /* libReact.a in Frameworks */, 362 | ); 363 | runOnlyForDeploymentPostprocessing = 0; 364 | }; 365 | 13B07F8C1A680F5B00A75B9A /* Frameworks */ = { 366 | isa = PBXFrameworksBuildPhase; 367 | buildActionMask = 2147483647; 368 | files = ( 369 | 6EADEE4920C78FCA00D10395 /* libRNDynamicSplash.a in Frameworks */, 370 | ADBDB9381DFEBF1600ED6528 /* libRCTBlob.a in Frameworks */, 371 | 5E9157361DD0AC6A00FF2AA8 /* libRCTAnimation.a in Frameworks */, 372 | 146834051AC3E58100842450 /* libReact.a in Frameworks */, 373 | 5E9157361DD0AC6A00FF2AA8 /* libRCTAnimation.a in Frameworks */, 374 | 00C302E51ABCBA2D00DB3ED1 /* libRCTActionSheet.a in Frameworks */, 375 | 00C302E71ABCBA2D00DB3ED1 /* libRCTGeolocation.a in Frameworks */, 376 | 00C302E81ABCBA2D00DB3ED1 /* libRCTImage.a in Frameworks */, 377 | 133E29F31AD74F7200F7D852 /* libRCTLinking.a in Frameworks */, 378 | 00C302E91ABCBA2D00DB3ED1 /* libRCTNetwork.a in Frameworks */, 379 | 139105C61AF99C1200B5F7CC /* libRCTSettings.a in Frameworks */, 380 | 832341BD1AAA6AB300B99B32 /* libRCTText.a in Frameworks */, 381 | 00C302EA1ABCBA2D00DB3ED1 /* libRCTVibration.a in Frameworks */, 382 | 139FDEF61B0652A700C62182 /* libRCTWebSocket.a in Frameworks */, 383 | ); 384 | runOnlyForDeploymentPostprocessing = 0; 385 | }; 386 | 2D02E4781E0B4A5D006451C7 /* Frameworks */ = { 387 | isa = PBXFrameworksBuildPhase; 388 | buildActionMask = 2147483647; 389 | files = ( 390 | 2D16E6881FA4F8E400B85C8A /* libReact.a in Frameworks */, 391 | 2D02E4C21E0B4AEC006451C7 /* libRCTAnimation.a in Frameworks */, 392 | 2D02E4C31E0B4AEC006451C7 /* libRCTImage-tvOS.a in Frameworks */, 393 | 2D02E4C41E0B4AEC006451C7 /* libRCTLinking-tvOS.a in Frameworks */, 394 | 2D02E4C51E0B4AEC006451C7 /* libRCTNetwork-tvOS.a in Frameworks */, 395 | 2D02E4C61E0B4AEC006451C7 /* libRCTSettings-tvOS.a in Frameworks */, 396 | 2D02E4C71E0B4AEC006451C7 /* libRCTText-tvOS.a in Frameworks */, 397 | 2D02E4C81E0B4AEC006451C7 /* libRCTWebSocket-tvOS.a in Frameworks */, 398 | ); 399 | runOnlyForDeploymentPostprocessing = 0; 400 | }; 401 | 2D02E48D1E0B4A5D006451C7 /* Frameworks */ = { 402 | isa = PBXFrameworksBuildPhase; 403 | buildActionMask = 2147483647; 404 | files = ( 405 | 2DF0FFEE2056DD460020B375 /* libReact.a in Frameworks */, 406 | ); 407 | runOnlyForDeploymentPostprocessing = 0; 408 | }; 409 | /* End PBXFrameworksBuildPhase section */ 410 | 411 | /* Begin PBXGroup section */ 412 | 00C302A81ABCB8CE00DB3ED1 /* Products */ = { 413 | isa = PBXGroup; 414 | children = ( 415 | 00C302AC1ABCB8CE00DB3ED1 /* libRCTActionSheet.a */, 416 | ); 417 | name = Products; 418 | sourceTree = ""; 419 | }; 420 | 00C302B61ABCB90400DB3ED1 /* Products */ = { 421 | isa = PBXGroup; 422 | children = ( 423 | 00C302BA1ABCB90400DB3ED1 /* libRCTGeolocation.a */, 424 | ); 425 | name = Products; 426 | sourceTree = ""; 427 | }; 428 | 00C302BC1ABCB91800DB3ED1 /* Products */ = { 429 | isa = PBXGroup; 430 | children = ( 431 | 00C302C01ABCB91800DB3ED1 /* libRCTImage.a */, 432 | 3DAD3E841DF850E9000B6D8A /* libRCTImage-tvOS.a */, 433 | ); 434 | name = Products; 435 | sourceTree = ""; 436 | }; 437 | 00C302D41ABCB9D200DB3ED1 /* Products */ = { 438 | isa = PBXGroup; 439 | children = ( 440 | 00C302DC1ABCB9D200DB3ED1 /* libRCTNetwork.a */, 441 | 3DAD3E8C1DF850E9000B6D8A /* libRCTNetwork-tvOS.a */, 442 | ); 443 | name = Products; 444 | sourceTree = ""; 445 | }; 446 | 00C302E01ABCB9EE00DB3ED1 /* Products */ = { 447 | isa = PBXGroup; 448 | children = ( 449 | 00C302E41ABCB9EE00DB3ED1 /* libRCTVibration.a */, 450 | ); 451 | name = Products; 452 | sourceTree = ""; 453 | }; 454 | 00E356EF1AD99517003FC87E /* exampleTests */ = { 455 | isa = PBXGroup; 456 | children = ( 457 | 00E356F21AD99517003FC87E /* exampleTests.m */, 458 | 00E356F01AD99517003FC87E /* Supporting Files */, 459 | ); 460 | path = exampleTests; 461 | sourceTree = ""; 462 | }; 463 | 00E356F01AD99517003FC87E /* Supporting Files */ = { 464 | isa = PBXGroup; 465 | children = ( 466 | 00E356F11AD99517003FC87E /* Info.plist */, 467 | ); 468 | name = "Supporting Files"; 469 | sourceTree = ""; 470 | }; 471 | 139105B71AF99BAD00B5F7CC /* Products */ = { 472 | isa = PBXGroup; 473 | children = ( 474 | 139105C11AF99BAD00B5F7CC /* libRCTSettings.a */, 475 | 3DAD3E901DF850E9000B6D8A /* libRCTSettings-tvOS.a */, 476 | ); 477 | name = Products; 478 | sourceTree = ""; 479 | }; 480 | 139FDEE71B06529A00C62182 /* Products */ = { 481 | isa = PBXGroup; 482 | children = ( 483 | 139FDEF41B06529B00C62182 /* libRCTWebSocket.a */, 484 | 3DAD3E991DF850E9000B6D8A /* libRCTWebSocket-tvOS.a */, 485 | 2D16E6841FA4F8DC00B85C8A /* libfishhook.a */, 486 | 2D16E6861FA4F8DC00B85C8A /* libfishhook-tvOS.a */, 487 | ); 488 | name = Products; 489 | sourceTree = ""; 490 | }; 491 | 13B07FAE1A68108700A75B9A /* example */ = { 492 | isa = PBXGroup; 493 | children = ( 494 | 008F07F21AC5B25A0029DE68 /* main.jsbundle */, 495 | 13B07FAF1A68108700A75B9A /* AppDelegate.h */, 496 | 13B07FB01A68108700A75B9A /* AppDelegate.m */, 497 | 6EADEE4A20C7C0D800D10395 /* Images.xcassets */, 498 | 13B07FB61A68108700A75B9A /* Info.plist */, 499 | 13B07FB11A68108700A75B9A /* LaunchScreen.xib */, 500 | 13B07FB71A68108700A75B9A /* main.m */, 501 | ); 502 | name = example; 503 | sourceTree = ""; 504 | }; 505 | 146834001AC3E56700842450 /* Products */ = { 506 | isa = PBXGroup; 507 | children = ( 508 | 146834041AC3E56700842450 /* libReact.a */, 509 | 3DAD3EA31DF850E9000B6D8A /* libReact.a */, 510 | 3DAD3EA51DF850E9000B6D8A /* libyoga.a */, 511 | 3DAD3EA71DF850E9000B6D8A /* libyoga.a */, 512 | 3DAD3EA91DF850E9000B6D8A /* libcxxreact.a */, 513 | 3DAD3EAB1DF850E9000B6D8A /* libcxxreact.a */, 514 | 3DAD3EAD1DF850E9000B6D8A /* libjschelpers.a */, 515 | 3DAD3EAF1DF850E9000B6D8A /* libjschelpers.a */, 516 | 2DF0FFDF2056DD460020B375 /* libjsinspector.a */, 517 | 2DF0FFE12056DD460020B375 /* libjsinspector-tvOS.a */, 518 | 2DF0FFE32056DD460020B375 /* libthird-party.a */, 519 | 2DF0FFE52056DD460020B375 /* libthird-party.a */, 520 | 2DF0FFE72056DD460020B375 /* libdouble-conversion.a */, 521 | 2DF0FFE92056DD460020B375 /* libdouble-conversion.a */, 522 | 2DF0FFEB2056DD460020B375 /* libprivatedata.a */, 523 | 2DF0FFED2056DD460020B375 /* libprivatedata-tvOS.a */, 524 | ); 525 | name = Products; 526 | sourceTree = ""; 527 | }; 528 | 2D16E6871FA4F8E400B85C8A /* Frameworks */ = { 529 | isa = PBXGroup; 530 | children = ( 531 | 2D16E6891FA4F8E400B85C8A /* libReact.a */, 532 | ); 533 | name = Frameworks; 534 | sourceTree = ""; 535 | }; 536 | 5E91572E1DD0AC6500FF2AA8 /* Products */ = { 537 | isa = PBXGroup; 538 | children = ( 539 | 5E9157331DD0AC6500FF2AA8 /* libRCTAnimation.a */, 540 | 5E9157351DD0AC6500FF2AA8 /* libRCTAnimation.a */, 541 | ); 542 | name = Products; 543 | sourceTree = ""; 544 | }; 545 | 6EADEE4420C78F8500D10395 /* Products */ = { 546 | isa = PBXGroup; 547 | children = ( 548 | 6EADEE4820C78F8500D10395 /* libRNDynamicSplash.a */, 549 | ); 550 | name = Products; 551 | sourceTree = ""; 552 | }; 553 | 78C398B11ACF4ADC00677621 /* Products */ = { 554 | isa = PBXGroup; 555 | children = ( 556 | 78C398B91ACF4ADC00677621 /* libRCTLinking.a */, 557 | 3DAD3E881DF850E9000B6D8A /* libRCTLinking-tvOS.a */, 558 | ); 559 | name = Products; 560 | sourceTree = ""; 561 | }; 562 | 832341AE1AAA6A7D00B99B32 /* Libraries */ = { 563 | isa = PBXGroup; 564 | children = ( 565 | 6EADEE4320C78F8500D10395 /* RNDynamicSplash.xcodeproj */, 566 | 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */, 567 | 146833FF1AC3E56700842450 /* React.xcodeproj */, 568 | 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */, 569 | ADBDB91F1DFEBF0600ED6528 /* RCTBlob.xcodeproj */, 570 | 00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */, 571 | 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */, 572 | 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */, 573 | 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */, 574 | 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */, 575 | 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */, 576 | 00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */, 577 | 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */, 578 | ); 579 | name = Libraries; 580 | sourceTree = ""; 581 | }; 582 | 832341B11AAA6A8300B99B32 /* Products */ = { 583 | isa = PBXGroup; 584 | children = ( 585 | 832341B51AAA6A8300B99B32 /* libRCTText.a */, 586 | 3DAD3E941DF850E9000B6D8A /* libRCTText-tvOS.a */, 587 | ); 588 | name = Products; 589 | sourceTree = ""; 590 | }; 591 | 83CBB9F61A601CBA00E9B192 = { 592 | isa = PBXGroup; 593 | children = ( 594 | 13B07FAE1A68108700A75B9A /* example */, 595 | 832341AE1AAA6A7D00B99B32 /* Libraries */, 596 | 00E356EF1AD99517003FC87E /* exampleTests */, 597 | 83CBBA001A601CBA00E9B192 /* Products */, 598 | 2D16E6871FA4F8E400B85C8A /* Frameworks */, 599 | ); 600 | indentWidth = 2; 601 | sourceTree = ""; 602 | tabWidth = 2; 603 | usesTabs = 0; 604 | }; 605 | 83CBBA001A601CBA00E9B192 /* Products */ = { 606 | isa = PBXGroup; 607 | children = ( 608 | 13B07F961A680F5B00A75B9A /* example.app */, 609 | 00E356EE1AD99517003FC87E /* exampleTests.xctest */, 610 | 2D02E47B1E0B4A5D006451C7 /* example-tvOS.app */, 611 | 2D02E4901E0B4A5D006451C7 /* example-tvOSTests.xctest */, 612 | ); 613 | name = Products; 614 | sourceTree = ""; 615 | }; 616 | ADBDB9201DFEBF0600ED6528 /* Products */ = { 617 | isa = PBXGroup; 618 | children = ( 619 | ADBDB9271DFEBF0700ED6528 /* libRCTBlob.a */, 620 | 2D16E6721FA4F8DC00B85C8A /* libRCTBlob-tvOS.a */, 621 | ); 622 | name = Products; 623 | sourceTree = ""; 624 | }; 625 | /* End PBXGroup section */ 626 | 627 | /* Begin PBXNativeTarget section */ 628 | 00E356ED1AD99517003FC87E /* exampleTests */ = { 629 | isa = PBXNativeTarget; 630 | buildConfigurationList = 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget "exampleTests" */; 631 | buildPhases = ( 632 | 00E356EA1AD99517003FC87E /* Sources */, 633 | 00E356EB1AD99517003FC87E /* Frameworks */, 634 | 00E356EC1AD99517003FC87E /* Resources */, 635 | ); 636 | buildRules = ( 637 | ); 638 | dependencies = ( 639 | 00E356F51AD99517003FC87E /* PBXTargetDependency */, 640 | ); 641 | name = exampleTests; 642 | productName = exampleTests; 643 | productReference = 00E356EE1AD99517003FC87E /* exampleTests.xctest */; 644 | productType = "com.apple.product-type.bundle.unit-test"; 645 | }; 646 | 13B07F861A680F5B00A75B9A /* example */ = { 647 | isa = PBXNativeTarget; 648 | buildConfigurationList = 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "example" */; 649 | buildPhases = ( 650 | 13B07F871A680F5B00A75B9A /* Sources */, 651 | 13B07F8C1A680F5B00A75B9A /* Frameworks */, 652 | 13B07F8E1A680F5B00A75B9A /* Resources */, 653 | 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */, 654 | ); 655 | buildRules = ( 656 | ); 657 | dependencies = ( 658 | ); 659 | name = example; 660 | productName = "Hello World"; 661 | productReference = 13B07F961A680F5B00A75B9A /* example.app */; 662 | productType = "com.apple.product-type.application"; 663 | }; 664 | 2D02E47A1E0B4A5D006451C7 /* example-tvOS */ = { 665 | isa = PBXNativeTarget; 666 | buildConfigurationList = 2D02E4BA1E0B4A5E006451C7 /* Build configuration list for PBXNativeTarget "example-tvOS" */; 667 | buildPhases = ( 668 | 2D02E4771E0B4A5D006451C7 /* Sources */, 669 | 2D02E4781E0B4A5D006451C7 /* Frameworks */, 670 | 2D02E4791E0B4A5D006451C7 /* Resources */, 671 | 2D02E4CB1E0B4B27006451C7 /* Bundle React Native Code And Images */, 672 | ); 673 | buildRules = ( 674 | ); 675 | dependencies = ( 676 | ); 677 | name = "example-tvOS"; 678 | productName = "example-tvOS"; 679 | productReference = 2D02E47B1E0B4A5D006451C7 /* example-tvOS.app */; 680 | productType = "com.apple.product-type.application"; 681 | }; 682 | 2D02E48F1E0B4A5D006451C7 /* example-tvOSTests */ = { 683 | isa = PBXNativeTarget; 684 | buildConfigurationList = 2D02E4BB1E0B4A5E006451C7 /* Build configuration list for PBXNativeTarget "example-tvOSTests" */; 685 | buildPhases = ( 686 | 2D02E48C1E0B4A5D006451C7 /* Sources */, 687 | 2D02E48D1E0B4A5D006451C7 /* Frameworks */, 688 | 2D02E48E1E0B4A5D006451C7 /* Resources */, 689 | ); 690 | buildRules = ( 691 | ); 692 | dependencies = ( 693 | 2D02E4921E0B4A5D006451C7 /* PBXTargetDependency */, 694 | ); 695 | name = "example-tvOSTests"; 696 | productName = "example-tvOSTests"; 697 | productReference = 2D02E4901E0B4A5D006451C7 /* example-tvOSTests.xctest */; 698 | productType = "com.apple.product-type.bundle.unit-test"; 699 | }; 700 | /* End PBXNativeTarget section */ 701 | 702 | /* Begin PBXProject section */ 703 | 83CBB9F71A601CBA00E9B192 /* Project object */ = { 704 | isa = PBXProject; 705 | attributes = { 706 | LastUpgradeCheck = 0610; 707 | ORGANIZATIONNAME = Facebook; 708 | TargetAttributes = { 709 | 00E356ED1AD99517003FC87E = { 710 | CreatedOnToolsVersion = 6.2; 711 | TestTargetID = 13B07F861A680F5B00A75B9A; 712 | }; 713 | 2D02E47A1E0B4A5D006451C7 = { 714 | CreatedOnToolsVersion = 8.2.1; 715 | ProvisioningStyle = Automatic; 716 | }; 717 | 2D02E48F1E0B4A5D006451C7 = { 718 | CreatedOnToolsVersion = 8.2.1; 719 | ProvisioningStyle = Automatic; 720 | TestTargetID = 2D02E47A1E0B4A5D006451C7; 721 | }; 722 | }; 723 | }; 724 | buildConfigurationList = 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "example" */; 725 | compatibilityVersion = "Xcode 3.2"; 726 | developmentRegion = English; 727 | hasScannedForEncodings = 0; 728 | knownRegions = ( 729 | en, 730 | Base, 731 | ); 732 | mainGroup = 83CBB9F61A601CBA00E9B192; 733 | productRefGroup = 83CBBA001A601CBA00E9B192 /* Products */; 734 | projectDirPath = ""; 735 | projectReferences = ( 736 | { 737 | ProductGroup = 00C302A81ABCB8CE00DB3ED1 /* Products */; 738 | ProjectRef = 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */; 739 | }, 740 | { 741 | ProductGroup = 5E91572E1DD0AC6500FF2AA8 /* Products */; 742 | ProjectRef = 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */; 743 | }, 744 | { 745 | ProductGroup = ADBDB9201DFEBF0600ED6528 /* Products */; 746 | ProjectRef = ADBDB91F1DFEBF0600ED6528 /* RCTBlob.xcodeproj */; 747 | }, 748 | { 749 | ProductGroup = 00C302B61ABCB90400DB3ED1 /* Products */; 750 | ProjectRef = 00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */; 751 | }, 752 | { 753 | ProductGroup = 00C302BC1ABCB91800DB3ED1 /* Products */; 754 | ProjectRef = 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */; 755 | }, 756 | { 757 | ProductGroup = 78C398B11ACF4ADC00677621 /* Products */; 758 | ProjectRef = 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */; 759 | }, 760 | { 761 | ProductGroup = 00C302D41ABCB9D200DB3ED1 /* Products */; 762 | ProjectRef = 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */; 763 | }, 764 | { 765 | ProductGroup = 139105B71AF99BAD00B5F7CC /* Products */; 766 | ProjectRef = 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */; 767 | }, 768 | { 769 | ProductGroup = 832341B11AAA6A8300B99B32 /* Products */; 770 | ProjectRef = 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */; 771 | }, 772 | { 773 | ProductGroup = 00C302E01ABCB9EE00DB3ED1 /* Products */; 774 | ProjectRef = 00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */; 775 | }, 776 | { 777 | ProductGroup = 139FDEE71B06529A00C62182 /* Products */; 778 | ProjectRef = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */; 779 | }, 780 | { 781 | ProductGroup = 146834001AC3E56700842450 /* Products */; 782 | ProjectRef = 146833FF1AC3E56700842450 /* React.xcodeproj */; 783 | }, 784 | { 785 | ProductGroup = 6EADEE4420C78F8500D10395 /* Products */; 786 | ProjectRef = 6EADEE4320C78F8500D10395 /* RNDynamicSplash.xcodeproj */; 787 | }, 788 | ); 789 | projectRoot = ""; 790 | targets = ( 791 | 13B07F861A680F5B00A75B9A /* example */, 792 | 00E356ED1AD99517003FC87E /* exampleTests */, 793 | 2D02E47A1E0B4A5D006451C7 /* example-tvOS */, 794 | 2D02E48F1E0B4A5D006451C7 /* example-tvOSTests */, 795 | ); 796 | }; 797 | /* End PBXProject section */ 798 | 799 | /* Begin PBXReferenceProxy section */ 800 | 00C302AC1ABCB8CE00DB3ED1 /* libRCTActionSheet.a */ = { 801 | isa = PBXReferenceProxy; 802 | fileType = archive.ar; 803 | path = libRCTActionSheet.a; 804 | remoteRef = 00C302AB1ABCB8CE00DB3ED1 /* PBXContainerItemProxy */; 805 | sourceTree = BUILT_PRODUCTS_DIR; 806 | }; 807 | 00C302BA1ABCB90400DB3ED1 /* libRCTGeolocation.a */ = { 808 | isa = PBXReferenceProxy; 809 | fileType = archive.ar; 810 | path = libRCTGeolocation.a; 811 | remoteRef = 00C302B91ABCB90400DB3ED1 /* PBXContainerItemProxy */; 812 | sourceTree = BUILT_PRODUCTS_DIR; 813 | }; 814 | 00C302C01ABCB91800DB3ED1 /* libRCTImage.a */ = { 815 | isa = PBXReferenceProxy; 816 | fileType = archive.ar; 817 | path = libRCTImage.a; 818 | remoteRef = 00C302BF1ABCB91800DB3ED1 /* PBXContainerItemProxy */; 819 | sourceTree = BUILT_PRODUCTS_DIR; 820 | }; 821 | 00C302DC1ABCB9D200DB3ED1 /* libRCTNetwork.a */ = { 822 | isa = PBXReferenceProxy; 823 | fileType = archive.ar; 824 | path = libRCTNetwork.a; 825 | remoteRef = 00C302DB1ABCB9D200DB3ED1 /* PBXContainerItemProxy */; 826 | sourceTree = BUILT_PRODUCTS_DIR; 827 | }; 828 | 00C302E41ABCB9EE00DB3ED1 /* libRCTVibration.a */ = { 829 | isa = PBXReferenceProxy; 830 | fileType = archive.ar; 831 | path = libRCTVibration.a; 832 | remoteRef = 00C302E31ABCB9EE00DB3ED1 /* PBXContainerItemProxy */; 833 | sourceTree = BUILT_PRODUCTS_DIR; 834 | }; 835 | 139105C11AF99BAD00B5F7CC /* libRCTSettings.a */ = { 836 | isa = PBXReferenceProxy; 837 | fileType = archive.ar; 838 | path = libRCTSettings.a; 839 | remoteRef = 139105C01AF99BAD00B5F7CC /* PBXContainerItemProxy */; 840 | sourceTree = BUILT_PRODUCTS_DIR; 841 | }; 842 | 139FDEF41B06529B00C62182 /* libRCTWebSocket.a */ = { 843 | isa = PBXReferenceProxy; 844 | fileType = archive.ar; 845 | path = libRCTWebSocket.a; 846 | remoteRef = 139FDEF31B06529B00C62182 /* PBXContainerItemProxy */; 847 | sourceTree = BUILT_PRODUCTS_DIR; 848 | }; 849 | 146834041AC3E56700842450 /* libReact.a */ = { 850 | isa = PBXReferenceProxy; 851 | fileType = archive.ar; 852 | path = libReact.a; 853 | remoteRef = 146834031AC3E56700842450 /* PBXContainerItemProxy */; 854 | sourceTree = BUILT_PRODUCTS_DIR; 855 | }; 856 | 2D16E6721FA4F8DC00B85C8A /* libRCTBlob-tvOS.a */ = { 857 | isa = PBXReferenceProxy; 858 | fileType = archive.ar; 859 | path = "libRCTBlob-tvOS.a"; 860 | remoteRef = 2D16E6711FA4F8DC00B85C8A /* PBXContainerItemProxy */; 861 | sourceTree = BUILT_PRODUCTS_DIR; 862 | }; 863 | 2D16E6841FA4F8DC00B85C8A /* libfishhook.a */ = { 864 | isa = PBXReferenceProxy; 865 | fileType = archive.ar; 866 | path = libfishhook.a; 867 | remoteRef = 2D16E6831FA4F8DC00B85C8A /* PBXContainerItemProxy */; 868 | sourceTree = BUILT_PRODUCTS_DIR; 869 | }; 870 | 2D16E6861FA4F8DC00B85C8A /* libfishhook-tvOS.a */ = { 871 | isa = PBXReferenceProxy; 872 | fileType = archive.ar; 873 | path = "libfishhook-tvOS.a"; 874 | remoteRef = 2D16E6851FA4F8DC00B85C8A /* PBXContainerItemProxy */; 875 | sourceTree = BUILT_PRODUCTS_DIR; 876 | }; 877 | 2DF0FFDF2056DD460020B375 /* libjsinspector.a */ = { 878 | isa = PBXReferenceProxy; 879 | fileType = archive.ar; 880 | path = libjsinspector.a; 881 | remoteRef = 2DF0FFDE2056DD460020B375 /* PBXContainerItemProxy */; 882 | sourceTree = BUILT_PRODUCTS_DIR; 883 | }; 884 | 2DF0FFE12056DD460020B375 /* libjsinspector-tvOS.a */ = { 885 | isa = PBXReferenceProxy; 886 | fileType = archive.ar; 887 | path = "libjsinspector-tvOS.a"; 888 | remoteRef = 2DF0FFE02056DD460020B375 /* PBXContainerItemProxy */; 889 | sourceTree = BUILT_PRODUCTS_DIR; 890 | }; 891 | 2DF0FFE32056DD460020B375 /* libthird-party.a */ = { 892 | isa = PBXReferenceProxy; 893 | fileType = archive.ar; 894 | path = "libthird-party.a"; 895 | remoteRef = 2DF0FFE22056DD460020B375 /* PBXContainerItemProxy */; 896 | sourceTree = BUILT_PRODUCTS_DIR; 897 | }; 898 | 2DF0FFE52056DD460020B375 /* libthird-party.a */ = { 899 | isa = PBXReferenceProxy; 900 | fileType = archive.ar; 901 | path = "libthird-party.a"; 902 | remoteRef = 2DF0FFE42056DD460020B375 /* PBXContainerItemProxy */; 903 | sourceTree = BUILT_PRODUCTS_DIR; 904 | }; 905 | 2DF0FFE72056DD460020B375 /* libdouble-conversion.a */ = { 906 | isa = PBXReferenceProxy; 907 | fileType = archive.ar; 908 | path = "libdouble-conversion.a"; 909 | remoteRef = 2DF0FFE62056DD460020B375 /* PBXContainerItemProxy */; 910 | sourceTree = BUILT_PRODUCTS_DIR; 911 | }; 912 | 2DF0FFE92056DD460020B375 /* libdouble-conversion.a */ = { 913 | isa = PBXReferenceProxy; 914 | fileType = archive.ar; 915 | path = "libdouble-conversion.a"; 916 | remoteRef = 2DF0FFE82056DD460020B375 /* PBXContainerItemProxy */; 917 | sourceTree = BUILT_PRODUCTS_DIR; 918 | }; 919 | 2DF0FFEB2056DD460020B375 /* libprivatedata.a */ = { 920 | isa = PBXReferenceProxy; 921 | fileType = archive.ar; 922 | path = libprivatedata.a; 923 | remoteRef = 2DF0FFEA2056DD460020B375 /* PBXContainerItemProxy */; 924 | sourceTree = BUILT_PRODUCTS_DIR; 925 | }; 926 | 2DF0FFED2056DD460020B375 /* libprivatedata-tvOS.a */ = { 927 | isa = PBXReferenceProxy; 928 | fileType = archive.ar; 929 | path = "libprivatedata-tvOS.a"; 930 | remoteRef = 2DF0FFEC2056DD460020B375 /* PBXContainerItemProxy */; 931 | sourceTree = BUILT_PRODUCTS_DIR; 932 | }; 933 | 3DAD3E841DF850E9000B6D8A /* libRCTImage-tvOS.a */ = { 934 | isa = PBXReferenceProxy; 935 | fileType = archive.ar; 936 | path = "libRCTImage-tvOS.a"; 937 | remoteRef = 3DAD3E831DF850E9000B6D8A /* PBXContainerItemProxy */; 938 | sourceTree = BUILT_PRODUCTS_DIR; 939 | }; 940 | 3DAD3E881DF850E9000B6D8A /* libRCTLinking-tvOS.a */ = { 941 | isa = PBXReferenceProxy; 942 | fileType = archive.ar; 943 | path = "libRCTLinking-tvOS.a"; 944 | remoteRef = 3DAD3E871DF850E9000B6D8A /* PBXContainerItemProxy */; 945 | sourceTree = BUILT_PRODUCTS_DIR; 946 | }; 947 | 3DAD3E8C1DF850E9000B6D8A /* libRCTNetwork-tvOS.a */ = { 948 | isa = PBXReferenceProxy; 949 | fileType = archive.ar; 950 | path = "libRCTNetwork-tvOS.a"; 951 | remoteRef = 3DAD3E8B1DF850E9000B6D8A /* PBXContainerItemProxy */; 952 | sourceTree = BUILT_PRODUCTS_DIR; 953 | }; 954 | 3DAD3E901DF850E9000B6D8A /* libRCTSettings-tvOS.a */ = { 955 | isa = PBXReferenceProxy; 956 | fileType = archive.ar; 957 | path = "libRCTSettings-tvOS.a"; 958 | remoteRef = 3DAD3E8F1DF850E9000B6D8A /* PBXContainerItemProxy */; 959 | sourceTree = BUILT_PRODUCTS_DIR; 960 | }; 961 | 3DAD3E941DF850E9000B6D8A /* libRCTText-tvOS.a */ = { 962 | isa = PBXReferenceProxy; 963 | fileType = archive.ar; 964 | path = "libRCTText-tvOS.a"; 965 | remoteRef = 3DAD3E931DF850E9000B6D8A /* PBXContainerItemProxy */; 966 | sourceTree = BUILT_PRODUCTS_DIR; 967 | }; 968 | 3DAD3E991DF850E9000B6D8A /* libRCTWebSocket-tvOS.a */ = { 969 | isa = PBXReferenceProxy; 970 | fileType = archive.ar; 971 | path = "libRCTWebSocket-tvOS.a"; 972 | remoteRef = 3DAD3E981DF850E9000B6D8A /* PBXContainerItemProxy */; 973 | sourceTree = BUILT_PRODUCTS_DIR; 974 | }; 975 | 3DAD3EA31DF850E9000B6D8A /* libReact.a */ = { 976 | isa = PBXReferenceProxy; 977 | fileType = archive.ar; 978 | path = libReact.a; 979 | remoteRef = 3DAD3EA21DF850E9000B6D8A /* PBXContainerItemProxy */; 980 | sourceTree = BUILT_PRODUCTS_DIR; 981 | }; 982 | 3DAD3EA51DF850E9000B6D8A /* libyoga.a */ = { 983 | isa = PBXReferenceProxy; 984 | fileType = archive.ar; 985 | path = libyoga.a; 986 | remoteRef = 3DAD3EA41DF850E9000B6D8A /* PBXContainerItemProxy */; 987 | sourceTree = BUILT_PRODUCTS_DIR; 988 | }; 989 | 3DAD3EA71DF850E9000B6D8A /* libyoga.a */ = { 990 | isa = PBXReferenceProxy; 991 | fileType = archive.ar; 992 | path = libyoga.a; 993 | remoteRef = 3DAD3EA61DF850E9000B6D8A /* PBXContainerItemProxy */; 994 | sourceTree = BUILT_PRODUCTS_DIR; 995 | }; 996 | 3DAD3EA91DF850E9000B6D8A /* libcxxreact.a */ = { 997 | isa = PBXReferenceProxy; 998 | fileType = archive.ar; 999 | path = libcxxreact.a; 1000 | remoteRef = 3DAD3EA81DF850E9000B6D8A /* PBXContainerItemProxy */; 1001 | sourceTree = BUILT_PRODUCTS_DIR; 1002 | }; 1003 | 3DAD3EAB1DF850E9000B6D8A /* libcxxreact.a */ = { 1004 | isa = PBXReferenceProxy; 1005 | fileType = archive.ar; 1006 | path = libcxxreact.a; 1007 | remoteRef = 3DAD3EAA1DF850E9000B6D8A /* PBXContainerItemProxy */; 1008 | sourceTree = BUILT_PRODUCTS_DIR; 1009 | }; 1010 | 3DAD3EAD1DF850E9000B6D8A /* libjschelpers.a */ = { 1011 | isa = PBXReferenceProxy; 1012 | fileType = archive.ar; 1013 | path = libjschelpers.a; 1014 | remoteRef = 3DAD3EAC1DF850E9000B6D8A /* PBXContainerItemProxy */; 1015 | sourceTree = BUILT_PRODUCTS_DIR; 1016 | }; 1017 | 3DAD3EAF1DF850E9000B6D8A /* libjschelpers.a */ = { 1018 | isa = PBXReferenceProxy; 1019 | fileType = archive.ar; 1020 | path = libjschelpers.a; 1021 | remoteRef = 3DAD3EAE1DF850E9000B6D8A /* PBXContainerItemProxy */; 1022 | sourceTree = BUILT_PRODUCTS_DIR; 1023 | }; 1024 | 5E9157331DD0AC6500FF2AA8 /* libRCTAnimation.a */ = { 1025 | isa = PBXReferenceProxy; 1026 | fileType = archive.ar; 1027 | path = libRCTAnimation.a; 1028 | remoteRef = 5E9157321DD0AC6500FF2AA8 /* PBXContainerItemProxy */; 1029 | sourceTree = BUILT_PRODUCTS_DIR; 1030 | }; 1031 | 5E9157351DD0AC6500FF2AA8 /* libRCTAnimation.a */ = { 1032 | isa = PBXReferenceProxy; 1033 | fileType = archive.ar; 1034 | path = libRCTAnimation.a; 1035 | remoteRef = 5E9157341DD0AC6500FF2AA8 /* PBXContainerItemProxy */; 1036 | sourceTree = BUILT_PRODUCTS_DIR; 1037 | }; 1038 | 6EADEE4820C78F8500D10395 /* libRNDynamicSplash.a */ = { 1039 | isa = PBXReferenceProxy; 1040 | fileType = archive.ar; 1041 | path = libRNDynamicSplash.a; 1042 | remoteRef = 6EADEE4720C78F8500D10395 /* PBXContainerItemProxy */; 1043 | sourceTree = BUILT_PRODUCTS_DIR; 1044 | }; 1045 | 78C398B91ACF4ADC00677621 /* libRCTLinking.a */ = { 1046 | isa = PBXReferenceProxy; 1047 | fileType = archive.ar; 1048 | path = libRCTLinking.a; 1049 | remoteRef = 78C398B81ACF4ADC00677621 /* PBXContainerItemProxy */; 1050 | sourceTree = BUILT_PRODUCTS_DIR; 1051 | }; 1052 | 832341B51AAA6A8300B99B32 /* libRCTText.a */ = { 1053 | isa = PBXReferenceProxy; 1054 | fileType = archive.ar; 1055 | path = libRCTText.a; 1056 | remoteRef = 832341B41AAA6A8300B99B32 /* PBXContainerItemProxy */; 1057 | sourceTree = BUILT_PRODUCTS_DIR; 1058 | }; 1059 | ADBDB9271DFEBF0700ED6528 /* libRCTBlob.a */ = { 1060 | isa = PBXReferenceProxy; 1061 | fileType = archive.ar; 1062 | path = libRCTBlob.a; 1063 | remoteRef = ADBDB9261DFEBF0700ED6528 /* PBXContainerItemProxy */; 1064 | sourceTree = BUILT_PRODUCTS_DIR; 1065 | }; 1066 | /* End PBXReferenceProxy section */ 1067 | 1068 | /* Begin PBXResourcesBuildPhase section */ 1069 | 00E356EC1AD99517003FC87E /* Resources */ = { 1070 | isa = PBXResourcesBuildPhase; 1071 | buildActionMask = 2147483647; 1072 | files = ( 1073 | ); 1074 | runOnlyForDeploymentPostprocessing = 0; 1075 | }; 1076 | 13B07F8E1A680F5B00A75B9A /* Resources */ = { 1077 | isa = PBXResourcesBuildPhase; 1078 | buildActionMask = 2147483647; 1079 | files = ( 1080 | 13B07FBD1A68108700A75B9A /* LaunchScreen.xib in Resources */, 1081 | 6EADEE4B20C7C0D800D10395 /* Images.xcassets in Resources */, 1082 | ); 1083 | runOnlyForDeploymentPostprocessing = 0; 1084 | }; 1085 | 2D02E4791E0B4A5D006451C7 /* Resources */ = { 1086 | isa = PBXResourcesBuildPhase; 1087 | buildActionMask = 2147483647; 1088 | files = ( 1089 | ); 1090 | runOnlyForDeploymentPostprocessing = 0; 1091 | }; 1092 | 2D02E48E1E0B4A5D006451C7 /* Resources */ = { 1093 | isa = PBXResourcesBuildPhase; 1094 | buildActionMask = 2147483647; 1095 | files = ( 1096 | ); 1097 | runOnlyForDeploymentPostprocessing = 0; 1098 | }; 1099 | /* End PBXResourcesBuildPhase section */ 1100 | 1101 | /* Begin PBXShellScriptBuildPhase section */ 1102 | 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */ = { 1103 | isa = PBXShellScriptBuildPhase; 1104 | buildActionMask = 2147483647; 1105 | files = ( 1106 | ); 1107 | inputPaths = ( 1108 | ); 1109 | name = "Bundle React Native code and images"; 1110 | outputPaths = ( 1111 | ); 1112 | runOnlyForDeploymentPostprocessing = 0; 1113 | shellPath = /bin/sh; 1114 | shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh"; 1115 | }; 1116 | 2D02E4CB1E0B4B27006451C7 /* Bundle React Native Code And Images */ = { 1117 | isa = PBXShellScriptBuildPhase; 1118 | buildActionMask = 2147483647; 1119 | files = ( 1120 | ); 1121 | inputPaths = ( 1122 | ); 1123 | name = "Bundle React Native Code And Images"; 1124 | outputPaths = ( 1125 | ); 1126 | runOnlyForDeploymentPostprocessing = 0; 1127 | shellPath = /bin/sh; 1128 | shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh"; 1129 | }; 1130 | /* End PBXShellScriptBuildPhase section */ 1131 | 1132 | /* Begin PBXSourcesBuildPhase section */ 1133 | 00E356EA1AD99517003FC87E /* Sources */ = { 1134 | isa = PBXSourcesBuildPhase; 1135 | buildActionMask = 2147483647; 1136 | files = ( 1137 | 00E356F31AD99517003FC87E /* exampleTests.m in Sources */, 1138 | ); 1139 | runOnlyForDeploymentPostprocessing = 0; 1140 | }; 1141 | 13B07F871A680F5B00A75B9A /* Sources */ = { 1142 | isa = PBXSourcesBuildPhase; 1143 | buildActionMask = 2147483647; 1144 | files = ( 1145 | 13B07FBC1A68108700A75B9A /* AppDelegate.m in Sources */, 1146 | 13B07FC11A68108700A75B9A /* main.m in Sources */, 1147 | ); 1148 | runOnlyForDeploymentPostprocessing = 0; 1149 | }; 1150 | 2D02E4771E0B4A5D006451C7 /* Sources */ = { 1151 | isa = PBXSourcesBuildPhase; 1152 | buildActionMask = 2147483647; 1153 | files = ( 1154 | 2D02E4BF1E0B4AB3006451C7 /* main.m in Sources */, 1155 | 2D02E4BC1E0B4A80006451C7 /* AppDelegate.m in Sources */, 1156 | ); 1157 | runOnlyForDeploymentPostprocessing = 0; 1158 | }; 1159 | 2D02E48C1E0B4A5D006451C7 /* Sources */ = { 1160 | isa = PBXSourcesBuildPhase; 1161 | buildActionMask = 2147483647; 1162 | files = ( 1163 | 2DCD954D1E0B4F2C00145EB5 /* exampleTests.m in Sources */, 1164 | ); 1165 | runOnlyForDeploymentPostprocessing = 0; 1166 | }; 1167 | /* End PBXSourcesBuildPhase section */ 1168 | 1169 | /* Begin PBXTargetDependency section */ 1170 | 00E356F51AD99517003FC87E /* PBXTargetDependency */ = { 1171 | isa = PBXTargetDependency; 1172 | target = 13B07F861A680F5B00A75B9A /* example */; 1173 | targetProxy = 00E356F41AD99517003FC87E /* PBXContainerItemProxy */; 1174 | }; 1175 | 2D02E4921E0B4A5D006451C7 /* PBXTargetDependency */ = { 1176 | isa = PBXTargetDependency; 1177 | target = 2D02E47A1E0B4A5D006451C7 /* example-tvOS */; 1178 | targetProxy = 2D02E4911E0B4A5D006451C7 /* PBXContainerItemProxy */; 1179 | }; 1180 | /* End PBXTargetDependency section */ 1181 | 1182 | /* Begin PBXVariantGroup section */ 1183 | 13B07FB11A68108700A75B9A /* LaunchScreen.xib */ = { 1184 | isa = PBXVariantGroup; 1185 | children = ( 1186 | 13B07FB21A68108700A75B9A /* Base */, 1187 | ); 1188 | name = LaunchScreen.xib; 1189 | path = example; 1190 | sourceTree = ""; 1191 | }; 1192 | /* End PBXVariantGroup section */ 1193 | 1194 | /* Begin XCBuildConfiguration section */ 1195 | 00E356F61AD99517003FC87E /* Debug */ = { 1196 | isa = XCBuildConfiguration; 1197 | buildSettings = { 1198 | BUNDLE_LOADER = "$(TEST_HOST)"; 1199 | GCC_PREPROCESSOR_DEFINITIONS = ( 1200 | "DEBUG=1", 1201 | "$(inherited)", 1202 | ); 1203 | INFOPLIST_FILE = exampleTests/Info.plist; 1204 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 1205 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 1206 | OTHER_LDFLAGS = ( 1207 | "-ObjC", 1208 | "-lc++", 1209 | ); 1210 | PRODUCT_NAME = "$(TARGET_NAME)"; 1211 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/example.app/example"; 1212 | }; 1213 | name = Debug; 1214 | }; 1215 | 00E356F71AD99517003FC87E /* Release */ = { 1216 | isa = XCBuildConfiguration; 1217 | buildSettings = { 1218 | BUNDLE_LOADER = "$(TEST_HOST)"; 1219 | COPY_PHASE_STRIP = NO; 1220 | INFOPLIST_FILE = exampleTests/Info.plist; 1221 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 1222 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 1223 | OTHER_LDFLAGS = ( 1224 | "-ObjC", 1225 | "-lc++", 1226 | ); 1227 | PRODUCT_NAME = "$(TARGET_NAME)"; 1228 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/example.app/example"; 1229 | }; 1230 | name = Release; 1231 | }; 1232 | 13B07F941A680F5B00A75B9A /* Debug */ = { 1233 | isa = XCBuildConfiguration; 1234 | buildSettings = { 1235 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 1236 | CURRENT_PROJECT_VERSION = 1; 1237 | DEAD_CODE_STRIPPING = NO; 1238 | HEADER_SEARCH_PATHS = "$(inherited)"; 1239 | INFOPLIST_FILE = example/Info.plist; 1240 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 1241 | LIBRARY_SEARCH_PATHS = ""; 1242 | OTHER_LDFLAGS = ( 1243 | "$(inherited)", 1244 | "-ObjC", 1245 | "-lc++", 1246 | ); 1247 | PRODUCT_NAME = example; 1248 | VERSIONING_SYSTEM = "apple-generic"; 1249 | }; 1250 | name = Debug; 1251 | }; 1252 | 13B07F951A680F5B00A75B9A /* Release */ = { 1253 | isa = XCBuildConfiguration; 1254 | buildSettings = { 1255 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 1256 | CURRENT_PROJECT_VERSION = 1; 1257 | HEADER_SEARCH_PATHS = "$(inherited)"; 1258 | INFOPLIST_FILE = example/Info.plist; 1259 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 1260 | LIBRARY_SEARCH_PATHS = ""; 1261 | OTHER_LDFLAGS = ( 1262 | "$(inherited)", 1263 | "-ObjC", 1264 | "-lc++", 1265 | ); 1266 | PRODUCT_NAME = example; 1267 | VERSIONING_SYSTEM = "apple-generic"; 1268 | }; 1269 | name = Release; 1270 | }; 1271 | 2D02E4971E0B4A5E006451C7 /* Debug */ = { 1272 | isa = XCBuildConfiguration; 1273 | buildSettings = { 1274 | ASSETCATALOG_COMPILER_APPICON_NAME = "App Icon & Top Shelf Image"; 1275 | ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage; 1276 | CLANG_ANALYZER_NONNULL = YES; 1277 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 1278 | CLANG_WARN_INFINITE_RECURSION = YES; 1279 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 1280 | DEBUG_INFORMATION_FORMAT = dwarf; 1281 | ENABLE_TESTABILITY = YES; 1282 | GCC_NO_COMMON_BLOCKS = YES; 1283 | INFOPLIST_FILE = "example-tvOS/Info.plist"; 1284 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 1285 | OTHER_LDFLAGS = ( 1286 | "-ObjC", 1287 | "-lc++", 1288 | ); 1289 | PRODUCT_BUNDLE_IDENTIFIER = "com.facebook.REACT.example-tvOS"; 1290 | PRODUCT_NAME = "$(TARGET_NAME)"; 1291 | SDKROOT = appletvos; 1292 | TARGETED_DEVICE_FAMILY = 3; 1293 | TVOS_DEPLOYMENT_TARGET = 9.2; 1294 | }; 1295 | name = Debug; 1296 | }; 1297 | 2D02E4981E0B4A5E006451C7 /* Release */ = { 1298 | isa = XCBuildConfiguration; 1299 | buildSettings = { 1300 | ASSETCATALOG_COMPILER_APPICON_NAME = "App Icon & Top Shelf Image"; 1301 | ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage; 1302 | CLANG_ANALYZER_NONNULL = YES; 1303 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 1304 | CLANG_WARN_INFINITE_RECURSION = YES; 1305 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 1306 | COPY_PHASE_STRIP = NO; 1307 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 1308 | GCC_NO_COMMON_BLOCKS = YES; 1309 | INFOPLIST_FILE = "example-tvOS/Info.plist"; 1310 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; 1311 | OTHER_LDFLAGS = ( 1312 | "-ObjC", 1313 | "-lc++", 1314 | ); 1315 | PRODUCT_BUNDLE_IDENTIFIER = "com.facebook.REACT.example-tvOS"; 1316 | PRODUCT_NAME = "$(TARGET_NAME)"; 1317 | SDKROOT = appletvos; 1318 | TARGETED_DEVICE_FAMILY = 3; 1319 | TVOS_DEPLOYMENT_TARGET = 9.2; 1320 | }; 1321 | name = Release; 1322 | }; 1323 | 2D02E4991E0B4A5E006451C7 /* Debug */ = { 1324 | isa = XCBuildConfiguration; 1325 | buildSettings = { 1326 | BUNDLE_LOADER = "$(TEST_HOST)"; 1327 | CLANG_ANALYZER_NONNULL = YES; 1328 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 1329 | CLANG_WARN_INFINITE_RECURSION = YES; 1330 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 1331 | DEBUG_INFORMATION_FORMAT = dwarf; 1332 | ENABLE_TESTABILITY = YES; 1333 | GCC_NO_COMMON_BLOCKS = YES; 1334 | INFOPLIST_FILE = "example-tvOSTests/Info.plist"; 1335 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 1336 | OTHER_LDFLAGS = ( 1337 | "-ObjC", 1338 | "-lc++", 1339 | ); 1340 | PRODUCT_BUNDLE_IDENTIFIER = "com.facebook.REACT.example-tvOSTests"; 1341 | PRODUCT_NAME = "$(TARGET_NAME)"; 1342 | SDKROOT = appletvos; 1343 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/example-tvOS.app/example-tvOS"; 1344 | TVOS_DEPLOYMENT_TARGET = 10.1; 1345 | }; 1346 | name = Debug; 1347 | }; 1348 | 2D02E49A1E0B4A5E006451C7 /* Release */ = { 1349 | isa = XCBuildConfiguration; 1350 | buildSettings = { 1351 | BUNDLE_LOADER = "$(TEST_HOST)"; 1352 | CLANG_ANALYZER_NONNULL = YES; 1353 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 1354 | CLANG_WARN_INFINITE_RECURSION = YES; 1355 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 1356 | COPY_PHASE_STRIP = NO; 1357 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 1358 | GCC_NO_COMMON_BLOCKS = YES; 1359 | INFOPLIST_FILE = "example-tvOSTests/Info.plist"; 1360 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; 1361 | OTHER_LDFLAGS = ( 1362 | "-ObjC", 1363 | "-lc++", 1364 | ); 1365 | PRODUCT_BUNDLE_IDENTIFIER = "com.facebook.REACT.example-tvOSTests"; 1366 | PRODUCT_NAME = "$(TARGET_NAME)"; 1367 | SDKROOT = appletvos; 1368 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/example-tvOS.app/example-tvOS"; 1369 | TVOS_DEPLOYMENT_TARGET = 10.1; 1370 | }; 1371 | name = Release; 1372 | }; 1373 | 83CBBA201A601CBA00E9B192 /* Debug */ = { 1374 | isa = XCBuildConfiguration; 1375 | buildSettings = { 1376 | ALWAYS_SEARCH_USER_PATHS = NO; 1377 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 1378 | CLANG_CXX_LIBRARY = "libc++"; 1379 | CLANG_ENABLE_MODULES = YES; 1380 | CLANG_ENABLE_OBJC_ARC = YES; 1381 | CLANG_WARN_BOOL_CONVERSION = YES; 1382 | CLANG_WARN_CONSTANT_CONVERSION = YES; 1383 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 1384 | CLANG_WARN_EMPTY_BODY = YES; 1385 | CLANG_WARN_ENUM_CONVERSION = YES; 1386 | CLANG_WARN_INT_CONVERSION = YES; 1387 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 1388 | CLANG_WARN_UNREACHABLE_CODE = YES; 1389 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 1390 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 1391 | COPY_PHASE_STRIP = NO; 1392 | ENABLE_STRICT_OBJC_MSGSEND = YES; 1393 | GCC_C_LANGUAGE_STANDARD = gnu99; 1394 | GCC_DYNAMIC_NO_PIC = NO; 1395 | GCC_OPTIMIZATION_LEVEL = 0; 1396 | GCC_PREPROCESSOR_DEFINITIONS = ( 1397 | "DEBUG=1", 1398 | "$(inherited)", 1399 | ); 1400 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 1401 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 1402 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 1403 | GCC_WARN_UNDECLARED_SELECTOR = YES; 1404 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 1405 | GCC_WARN_UNUSED_FUNCTION = YES; 1406 | GCC_WARN_UNUSED_VARIABLE = YES; 1407 | HEADER_SEARCH_PATHS = "$(SRCROOT)/../../ios/**"; 1408 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 1409 | LIBRARY_SEARCH_PATHS = ""; 1410 | MTL_ENABLE_DEBUG_INFO = YES; 1411 | ONLY_ACTIVE_ARCH = YES; 1412 | SDKROOT = iphoneos; 1413 | }; 1414 | name = Debug; 1415 | }; 1416 | 83CBBA211A601CBA00E9B192 /* Release */ = { 1417 | isa = XCBuildConfiguration; 1418 | buildSettings = { 1419 | ALWAYS_SEARCH_USER_PATHS = NO; 1420 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; 1421 | CLANG_CXX_LIBRARY = "libc++"; 1422 | CLANG_ENABLE_MODULES = YES; 1423 | CLANG_ENABLE_OBJC_ARC = YES; 1424 | CLANG_WARN_BOOL_CONVERSION = YES; 1425 | CLANG_WARN_CONSTANT_CONVERSION = YES; 1426 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 1427 | CLANG_WARN_EMPTY_BODY = YES; 1428 | CLANG_WARN_ENUM_CONVERSION = YES; 1429 | CLANG_WARN_INT_CONVERSION = YES; 1430 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 1431 | CLANG_WARN_UNREACHABLE_CODE = YES; 1432 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 1433 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 1434 | COPY_PHASE_STRIP = YES; 1435 | ENABLE_NS_ASSERTIONS = NO; 1436 | ENABLE_STRICT_OBJC_MSGSEND = YES; 1437 | GCC_C_LANGUAGE_STANDARD = gnu99; 1438 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 1439 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 1440 | GCC_WARN_UNDECLARED_SELECTOR = YES; 1441 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 1442 | GCC_WARN_UNUSED_FUNCTION = YES; 1443 | GCC_WARN_UNUSED_VARIABLE = YES; 1444 | HEADER_SEARCH_PATHS = "$(SRCROOT)/../../ios/**"; 1445 | IPHONEOS_DEPLOYMENT_TARGET = 8.0; 1446 | LIBRARY_SEARCH_PATHS = ""; 1447 | MTL_ENABLE_DEBUG_INFO = NO; 1448 | SDKROOT = iphoneos; 1449 | VALIDATE_PRODUCT = YES; 1450 | }; 1451 | name = Release; 1452 | }; 1453 | /* End XCBuildConfiguration section */ 1454 | 1455 | /* Begin XCConfigurationList section */ 1456 | 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget "exampleTests" */ = { 1457 | isa = XCConfigurationList; 1458 | buildConfigurations = ( 1459 | 00E356F61AD99517003FC87E /* Debug */, 1460 | 00E356F71AD99517003FC87E /* Release */, 1461 | ); 1462 | defaultConfigurationIsVisible = 0; 1463 | defaultConfigurationName = Release; 1464 | }; 1465 | 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "example" */ = { 1466 | isa = XCConfigurationList; 1467 | buildConfigurations = ( 1468 | 13B07F941A680F5B00A75B9A /* Debug */, 1469 | 13B07F951A680F5B00A75B9A /* Release */, 1470 | ); 1471 | defaultConfigurationIsVisible = 0; 1472 | defaultConfigurationName = Release; 1473 | }; 1474 | 2D02E4BA1E0B4A5E006451C7 /* Build configuration list for PBXNativeTarget "example-tvOS" */ = { 1475 | isa = XCConfigurationList; 1476 | buildConfigurations = ( 1477 | 2D02E4971E0B4A5E006451C7 /* Debug */, 1478 | 2D02E4981E0B4A5E006451C7 /* Release */, 1479 | ); 1480 | defaultConfigurationIsVisible = 0; 1481 | defaultConfigurationName = Release; 1482 | }; 1483 | 2D02E4BB1E0B4A5E006451C7 /* Build configuration list for PBXNativeTarget "example-tvOSTests" */ = { 1484 | isa = XCConfigurationList; 1485 | buildConfigurations = ( 1486 | 2D02E4991E0B4A5E006451C7 /* Debug */, 1487 | 2D02E49A1E0B4A5E006451C7 /* Release */, 1488 | ); 1489 | defaultConfigurationIsVisible = 0; 1490 | defaultConfigurationName = Release; 1491 | }; 1492 | 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "example" */ = { 1493 | isa = XCConfigurationList; 1494 | buildConfigurations = ( 1495 | 83CBBA201A601CBA00E9B192 /* Debug */, 1496 | 83CBBA211A601CBA00E9B192 /* Release */, 1497 | ); 1498 | defaultConfigurationIsVisible = 0; 1499 | defaultConfigurationName = Release; 1500 | }; 1501 | /* End XCConfigurationList section */ 1502 | }; 1503 | rootObject = 83CBB9F71A601CBA00E9B192 /* Project object */; 1504 | } 1505 | -------------------------------------------------------------------------------- /example/ios/example.xcodeproj/xcshareddata/xcschemes/example-tvOS.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 29 | 35 | 36 | 37 | 43 | 49 | 50 | 51 | 52 | 53 | 58 | 59 | 61 | 67 | 68 | 69 | 70 | 71 | 77 | 78 | 79 | 80 | 81 | 82 | 92 | 94 | 100 | 101 | 102 | 103 | 104 | 105 | 111 | 113 | 119 | 120 | 121 | 122 | 124 | 125 | 128 | 129 | 130 | -------------------------------------------------------------------------------- /example/ios/example.xcodeproj/xcshareddata/xcschemes/example.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 29 | 35 | 36 | 37 | 43 | 49 | 50 | 51 | 52 | 53 | 58 | 59 | 61 | 67 | 68 | 69 | 70 | 71 | 77 | 78 | 79 | 80 | 81 | 82 | 92 | 94 | 100 | 101 | 102 | 103 | 104 | 105 | 111 | 113 | 119 | 120 | 121 | 122 | 124 | 125 | 128 | 129 | 130 | -------------------------------------------------------------------------------- /example/ios/example/AppDelegate.h: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) 2015-present, Facebook, Inc. 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 9 | 10 | @interface AppDelegate : UIResponder 11 | 12 | @property (nonatomic, strong) UIWindow *window; 13 | 14 | @end 15 | -------------------------------------------------------------------------------- /example/ios/example/AppDelegate.m: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) 2015-present, Facebook, Inc. 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 11 | #import 12 | #import "RNDynamicSplash.h" 13 | #import "SplashConfig.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 | 35 | SplashConfig *config = [[SplashConfig alloc] init]; 36 | config.imageUrl = @"http://chuantu.biz/t6/315/1526808193x-1404792987.png"; 37 | config.autoHide = true; 38 | // config.autoHideTime = 1000; 39 | // config.dynamicShow = false; 40 | // config.autoDownload = false; 41 | // config.splashSavePath = @"custom"; 42 | [[RNDynamicSplash alloc] initWithShow:rootView splashConfig:config]; 43 | 44 | return YES; 45 | } 46 | 47 | @end 48 | -------------------------------------------------------------------------------- /example/ios/example/Base.lproj/LaunchScreen.xib: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | -------------------------------------------------------------------------------- /example/ios/example/Images.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "iphone", 5 | "size" : "20x20", 6 | "scale" : "2x" 7 | }, 8 | { 9 | "idiom" : "iphone", 10 | "size" : "20x20", 11 | "scale" : "3x" 12 | }, 13 | { 14 | "idiom" : "iphone", 15 | "size" : "29x29", 16 | "scale" : "2x" 17 | }, 18 | { 19 | "idiom" : "iphone", 20 | "size" : "29x29", 21 | "scale" : "3x" 22 | }, 23 | { 24 | "idiom" : "iphone", 25 | "size" : "40x40", 26 | "scale" : "2x" 27 | }, 28 | { 29 | "idiom" : "iphone", 30 | "size" : "40x40", 31 | "scale" : "3x" 32 | }, 33 | { 34 | "idiom" : "iphone", 35 | "size" : "60x60", 36 | "scale" : "2x" 37 | }, 38 | { 39 | "idiom" : "iphone", 40 | "size" : "60x60", 41 | "scale" : "3x" 42 | }, 43 | { 44 | "idiom" : "ios-marketing", 45 | "size" : "1024x1024", 46 | "scale" : "1x" 47 | } 48 | ], 49 | "info" : { 50 | "version" : 1, 51 | "author" : "xcode" 52 | } 53 | } -------------------------------------------------------------------------------- /example/ios/example/Images.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } -------------------------------------------------------------------------------- /example/ios/example/Images.xcassets/Splash.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "splash.png" 6 | } 7 | ], 8 | "info" : { 9 | "version" : 1, 10 | "author" : "xcode" 11 | } 12 | } -------------------------------------------------------------------------------- /example/ios/example/Images.xcassets/Splash.imageset/splash.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TaumuLu/react-native-dynamic-splash/a3d368126f8ab1152c29ec0d65a311a8ee8b5593/example/ios/example/Images.xcassets/Splash.imageset/splash.png -------------------------------------------------------------------------------- /example/ios/example/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleDisplayName 8 | example 9 | CFBundleExecutable 10 | $(EXECUTABLE_NAME) 11 | CFBundleIdentifier 12 | org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | $(PRODUCT_NAME) 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | 1.0 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | 1 25 | LSRequiresIPhoneOS 26 | 27 | NSAppTransportSecurity 28 | 29 | NSAllowsArbitraryLoads 30 | 31 | NSExceptionDomains 32 | 33 | localhost 34 | 35 | NSExceptionAllowsInsecureHTTPLoads 36 | 37 | 38 | 39 | 40 | NSLocationWhenInUseUsageDescription 41 | 42 | UILaunchStoryboardName 43 | LaunchScreen 44 | UIRequiredDeviceCapabilities 45 | 46 | armv7 47 | 48 | UISupportedInterfaceOrientations 49 | 50 | UIInterfaceOrientationPortrait 51 | UIInterfaceOrientationLandscapeLeft 52 | UIInterfaceOrientationLandscapeRight 53 | 54 | UIViewControllerBasedStatusBarAppearance 55 | 56 | 57 | 58 | -------------------------------------------------------------------------------- /example/ios/example/main.m: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) 2015-present, Facebook, Inc. 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 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 | } 17 | -------------------------------------------------------------------------------- /example/ios/exampleTests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | BNDL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | 24 | 25 | -------------------------------------------------------------------------------- /example/ios/exampleTests/exampleTests.m: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) 2015-present, Facebook, Inc. 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 9 | #import 10 | 11 | #import 12 | #import 13 | 14 | #define TIMEOUT_SECONDS 600 15 | #define TEXT_TO_LOOK_FOR @"Welcome to React Native!" 16 | 17 | @interface exampleTests : XCTestCase 18 | 19 | @end 20 | 21 | @implementation exampleTests 22 | 23 | - (BOOL)findSubviewInView:(UIView *)view matching:(BOOL(^)(UIView *view))test 24 | { 25 | if (test(view)) { 26 | return YES; 27 | } 28 | for (UIView *subview in [view subviews]) { 29 | if ([self findSubviewInView:subview matching:test]) { 30 | return YES; 31 | } 32 | } 33 | return NO; 34 | } 35 | 36 | - (void)testRendersWelcomeScreen 37 | { 38 | UIViewController *vc = [[[RCTSharedApplication() delegate] window] rootViewController]; 39 | NSDate *date = [NSDate dateWithTimeIntervalSinceNow:TIMEOUT_SECONDS]; 40 | BOOL foundElement = NO; 41 | 42 | __block NSString *redboxError = nil; 43 | RCTSetLogFunction(^(RCTLogLevel level, RCTLogSource source, NSString *fileName, NSNumber *lineNumber, NSString *message) { 44 | if (level >= RCTLogLevelError) { 45 | redboxError = message; 46 | } 47 | }); 48 | 49 | while ([date timeIntervalSinceNow] > 0 && !foundElement && !redboxError) { 50 | [[NSRunLoop mainRunLoop] runMode:NSDefaultRunLoopMode beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]]; 51 | [[NSRunLoop mainRunLoop] runMode:NSRunLoopCommonModes beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]]; 52 | 53 | foundElement = [self findSubviewInView:vc.view matching:^BOOL(UIView *view) { 54 | if ([view.accessibilityLabel isEqualToString:TEXT_TO_LOOK_FOR]) { 55 | return YES; 56 | } 57 | return NO; 58 | }]; 59 | } 60 | 61 | RCTSetLogFunction(RCTDefaultLogFunction); 62 | 63 | XCTAssertNil(redboxError, @"RedBox error: %@", redboxError); 64 | XCTAssertTrue(foundElement, @"Couldn't find element with text '%@' in %d seconds", TEXT_TO_LOOK_FOR, TIMEOUT_SECONDS); 65 | } 66 | 67 | 68 | @end 69 | -------------------------------------------------------------------------------- /example/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "example", 3 | "version": "0.0.1", 4 | "private": true, 5 | "scripts": { 6 | "start": "node node_modules/react-native/local-cli/cli.js start", 7 | "test": "jest" 8 | }, 9 | "dependencies": { 10 | "react": "16.3.1", 11 | "react-native": "0.55.4", 12 | "react-native-dynamic-splash": "^1.1.0" 13 | }, 14 | "devDependencies": { 15 | "babel-jest": "22.4.4", 16 | "babel-preset-react-native": "4.0.0", 17 | "jest": "22.4.4", 18 | "react-test-renderer": "16.3.1" 19 | }, 20 | "jest": { 21 | "preset": "react-native" 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /index.js: -------------------------------------------------------------------------------- 1 | const NativeModules = require('react-native') 2 | 3 | module.exports = NativeModules.DynamicSplash; 4 | -------------------------------------------------------------------------------- /ios/RNDynamicSplash.h: -------------------------------------------------------------------------------- 1 | // 2 | // RNDynamicSplash.h 3 | // RNDynamicSplash 4 | // 5 | // Created by mt on 2018/5/20. 6 | // Copyright © 2018年 mt. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | #import 12 | #import "SplashConfig.h" 13 | 14 | @interface RNDynamicSplash : NSObject 15 | 16 | - (id)initWithShow:(RCTRootView *)rootView splashConfig:(SplashConfig *)config; 17 | - (void)hide; 18 | - (void)downloadSplash; 19 | 20 | @end 21 | -------------------------------------------------------------------------------- /ios/RNDynamicSplash.m: -------------------------------------------------------------------------------- 1 | // 2 | // RNDynamicSplash.m 3 | // RNDynamicSplash 4 | // 5 | // Created by mt on 2018/5/20. 6 | // Copyright © 2018年 mt. All rights reserved. 7 | // 8 | 9 | #import "RNDynamicSplash.h" 10 | #import "Utils.h" 11 | #import "FileUtils.h" 12 | 13 | 14 | @interface RNDynamicSplash() { 15 | RCTRootView *_rootView; 16 | NSString *_fileName; 17 | NSString *_userDefaultsKey; 18 | NSString *_docsdir; 19 | SplashConfig *_config; 20 | } 21 | 22 | - (void)autoHide; 23 | - (UIImageView *)getImageView; 24 | - (UIImage *)getImage; 25 | 26 | @end 27 | 28 | @implementation RNDynamicSplash 29 | 30 | - (id)initWithShow:(RCTRootView *)rootView splashConfig:(SplashConfig *)config { 31 | if(self = [super init]) { 32 | // init 33 | _config = config; 34 | _rootView = rootView; 35 | _userDefaultsKey = @"dynamicSplashConfig"; 36 | _fileName = @"dynamicSplashImage"; 37 | NSString *docsdir = [NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) objectAtIndex:0]; 38 | // document目录拼接自定义目录 39 | _config.splashSavePath = [docsdir stringByAppendingPathComponent:_config.splashSavePath]; 40 | UIImageView *imageView = [self getImageView]; 41 | 42 | if(_config.autoDownload) { 43 | [self downloadSplashImg]; 44 | } 45 | 46 | [[NSNotificationCenter defaultCenter] removeObserver:_rootView name:RCTContentDidAppearNotification object:_rootView]; 47 | 48 | [_rootView setLoadingView:imageView]; 49 | if (_config.autoHide) { 50 | [self autoHide]; 51 | } 52 | } 53 | return self; 54 | } 55 | 56 | - (UIImageView *)getImageView { 57 | UIImageView *imageView = [[UIImageView alloc]initWithFrame:[UIScreen mainScreen].bounds]; 58 | 59 | imageView.image = [self getImage]; 60 | imageView.contentMode = UIViewContentModeScaleToFill; 61 | imageView.backgroundColor = [UIColor whiteColor]; 62 | imageView.userInteractionEnabled = YES; 63 | // UIViewContentModeScaleAspectFill; 64 | return imageView; 65 | } 66 | 67 | - (UIImage *)getImage { 68 | if(_config.dynamicShow) { 69 | UIImage * localImage = [FileUtils loadImage:_fileName inDirectory:_config.splashSavePath]; 70 | // NSArray *file = [[[NSFileManager alloc] init] subpathsAtPath:documentsDirectoryPath]; 71 | if(localImage != nil) { 72 | return localImage; 73 | } 74 | } 75 | 76 | // NSString *launchImageName = [[NSBundle mainBundle] pathForResource:@"LaunchImage" ofType:@"png"]; 77 | NSString *launchImageName = [FileUtils getLaunchImageName]; 78 | if(![Utils isBlankString: launchImageName]) { 79 | return [UIImage imageNamed:launchImageName]; 80 | } 81 | return [UIImage imageNamed:@"Splash"]; 82 | } 83 | 84 | - (void)autoHide { 85 | float time = _config.autoHideTime / 1000; 86 | [NSTimer scheduledTimerWithTimeInterval:time target:self selector:@selector(hideImg) userInfo:nil repeats:NO]; 87 | } 88 | 89 | - (void)hideImg { 90 | if (!_rootView) { 91 | return; 92 | } 93 | 94 | dispatch_async(dispatch_get_main_queue(), ^{ 95 | [self->_rootView.loadingView removeFromSuperview]; 96 | // [_rootView hideLoadingView]; 97 | }); 98 | } 99 | 100 | - (void)downloadSplashImg { 101 | NSString *imageUrl = _config.imageUrl; 102 | if(![Utils isBlankString: imageUrl]) { 103 | // 获得NSUserDefaults文件 104 | NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults]; 105 | NSString *splashConfig = [userDefaults objectForKey:_userDefaultsKey]; 106 | // 拼接保存路径和图片名作为标识 107 | NSString *imageName = [_config.splashSavePath stringByAppendingPathComponent:[FileUtils getImageName:imageUrl]]; 108 | if(![splashConfig isEqualToString:imageName]) { 109 | UIImage *image = [FileUtils getImageFromURL:imageUrl]; 110 | [FileUtils saveImage:image withFileName:_fileName inDirectory:_config.splashSavePath]; 111 | } else { 112 | [userDefaults setObject:imageName forKey:_userDefaultsKey]; 113 | } 114 | } 115 | } 116 | 117 | RCT_EXPORT_MODULE(); 118 | 119 | RCT_EXPORT_METHOD(hide) { 120 | [self hideImg]; 121 | } 122 | 123 | RCT_EXPORT_METHOD(downloadSplash) { 124 | [self downloadSplashImg]; 125 | } 126 | 127 | @end 128 | -------------------------------------------------------------------------------- /ios/RNDynamicSplash.podspec: -------------------------------------------------------------------------------- 1 | require "json" 2 | 3 | package = JSON.parse(File.read(File.join(__dir__, "../package.json"))) 4 | 5 | Pod::Spec.new do |s| 6 | s.name = "RNDynamicSplash" 7 | s.version = package["version"] 8 | s.summary = package["description"] 9 | s.description = package["description"] 10 | s.homepage = package["homepage"] 11 | s.license = package["license"] 12 | s.author = { "author" => package["author"]["email"] } 13 | s.platform = :ios, "7.0" 14 | s.source = { :git => "#{package["repository"]["baseUrl"]}.git", :tag => "#{s.version}" } 15 | 16 | s.source_files = "**/*.{swift,h,m}" 17 | s.requires_arc = true 18 | 19 | s.dependency "React" 20 | end 21 | -------------------------------------------------------------------------------- /ios/RNDynamicSplash.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 50; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 6EADED5720C6CC1100D10395 /* HttpUtils.m in Sources */ = {isa = PBXBuildFile; fileRef = 6EADED5620C6CC1100D10395 /* HttpUtils.m */; }; 11 | 6EADED5A20C6CC3900D10395 /* FileUtils.m in Sources */ = {isa = PBXBuildFile; fileRef = 6EADED5920C6CC3900D10395 /* FileUtils.m */; }; 12 | 6EADED9520C7875D00D10395 /* SplashConfig.m in Sources */ = {isa = PBXBuildFile; fileRef = 6EADED9420C7875D00D10395 /* SplashConfig.m */; }; 13 | 6EF65A2120B17BCA0076D1FA /* RNDynamicSplash.m in Sources */ = {isa = PBXBuildFile; fileRef = 6EF65A2020B17BCA0076D1FA /* RNDynamicSplash.m */; }; 14 | 6EF65A2220B17BCA0076D1FA /* RNDynamicSplash.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 6EF65A1F20B17BCA0076D1FA /* RNDynamicSplash.h */; }; 15 | 6EF65A2920B17E7A0076D1FA /* Utils.m in Sources */ = {isa = PBXBuildFile; fileRef = 6EF65A2820B17E7A0076D1FA /* Utils.m */; }; 16 | /* End PBXBuildFile section */ 17 | 18 | /* Begin PBXCopyFilesBuildPhase section */ 19 | 6EF65A1A20B17BCA0076D1FA /* CopyFiles */ = { 20 | isa = PBXCopyFilesBuildPhase; 21 | buildActionMask = 2147483647; 22 | dstPath = "include/$(PRODUCT_NAME)"; 23 | dstSubfolderSpec = 16; 24 | files = ( 25 | 6EF65A2220B17BCA0076D1FA /* RNDynamicSplash.h in CopyFiles */, 26 | ); 27 | runOnlyForDeploymentPostprocessing = 0; 28 | }; 29 | /* End PBXCopyFilesBuildPhase section */ 30 | 31 | /* Begin PBXFileReference section */ 32 | 6EADED5520C6CC1100D10395 /* HttpUtils.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = HttpUtils.h; sourceTree = ""; }; 33 | 6EADED5620C6CC1100D10395 /* HttpUtils.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = HttpUtils.m; sourceTree = ""; }; 34 | 6EADED5820C6CC3900D10395 /* FileUtils.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = FileUtils.h; sourceTree = ""; }; 35 | 6EADED5920C6CC3900D10395 /* FileUtils.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = FileUtils.m; sourceTree = ""; }; 36 | 6EADED9320C7875D00D10395 /* SplashConfig.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SplashConfig.h; sourceTree = ""; }; 37 | 6EADED9420C7875D00D10395 /* SplashConfig.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SplashConfig.m; sourceTree = ""; }; 38 | 6EF65A1C20B17BCA0076D1FA /* libRNDynamicSplash.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libRNDynamicSplash.a; sourceTree = BUILT_PRODUCTS_DIR; }; 39 | 6EF65A1F20B17BCA0076D1FA /* RNDynamicSplash.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = RNDynamicSplash.h; sourceTree = ""; }; 40 | 6EF65A2020B17BCA0076D1FA /* RNDynamicSplash.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = RNDynamicSplash.m; sourceTree = ""; }; 41 | 6EF65A2820B17E7A0076D1FA /* Utils.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = Utils.m; sourceTree = ""; }; 42 | 6EF65A2A20B17E990076D1FA /* Utils.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = Utils.h; sourceTree = ""; }; 43 | /* End PBXFileReference section */ 44 | 45 | /* Begin PBXFrameworksBuildPhase section */ 46 | 6EF65A1920B17BCA0076D1FA /* Frameworks */ = { 47 | isa = PBXFrameworksBuildPhase; 48 | buildActionMask = 2147483647; 49 | files = ( 50 | ); 51 | runOnlyForDeploymentPostprocessing = 0; 52 | }; 53 | /* End PBXFrameworksBuildPhase section */ 54 | 55 | /* Begin PBXGroup section */ 56 | 6E2717D320C0487C0044E0B5 /* Utils */ = { 57 | isa = PBXGroup; 58 | children = ( 59 | 6EADED9320C7875D00D10395 /* SplashConfig.h */, 60 | 6EADED9420C7875D00D10395 /* SplashConfig.m */, 61 | 6EADED5820C6CC3900D10395 /* FileUtils.h */, 62 | 6EADED5920C6CC3900D10395 /* FileUtils.m */, 63 | 6EF65A2A20B17E990076D1FA /* Utils.h */, 64 | 6EF65A2820B17E7A0076D1FA /* Utils.m */, 65 | 6EADED5520C6CC1100D10395 /* HttpUtils.h */, 66 | 6EADED5620C6CC1100D10395 /* HttpUtils.m */, 67 | ); 68 | path = Utils; 69 | sourceTree = ""; 70 | }; 71 | 6EF65A1320B17BCA0076D1FA = { 72 | isa = PBXGroup; 73 | children = ( 74 | 6E2717D320C0487C0044E0B5 /* Utils */, 75 | 6EF65A1D20B17BCA0076D1FA /* Products */, 76 | 6EF65A1F20B17BCA0076D1FA /* RNDynamicSplash.h */, 77 | 6EF65A2020B17BCA0076D1FA /* RNDynamicSplash.m */, 78 | ); 79 | sourceTree = ""; 80 | }; 81 | 6EF65A1D20B17BCA0076D1FA /* Products */ = { 82 | isa = PBXGroup; 83 | children = ( 84 | 6EF65A1C20B17BCA0076D1FA /* libRNDynamicSplash.a */, 85 | ); 86 | name = Products; 87 | sourceTree = ""; 88 | }; 89 | /* End PBXGroup section */ 90 | 91 | /* Begin PBXNativeTarget section */ 92 | 6EF65A1B20B17BCA0076D1FA /* RNDynamicSplash */ = { 93 | isa = PBXNativeTarget; 94 | buildConfigurationList = 6EF65A2520B17BCA0076D1FA /* Build configuration list for PBXNativeTarget "RNDynamicSplash" */; 95 | buildPhases = ( 96 | 6EF65A1820B17BCA0076D1FA /* Sources */, 97 | 6EF65A1920B17BCA0076D1FA /* Frameworks */, 98 | 6EF65A1A20B17BCA0076D1FA /* CopyFiles */, 99 | ); 100 | buildRules = ( 101 | ); 102 | dependencies = ( 103 | ); 104 | name = RNDynamicSplash; 105 | productName = RNDynamicSplash; 106 | productReference = 6EF65A1C20B17BCA0076D1FA /* libRNDynamicSplash.a */; 107 | productType = "com.apple.product-type.library.static"; 108 | }; 109 | /* End PBXNativeTarget section */ 110 | 111 | /* Begin PBXProject section */ 112 | 6EF65A1420B17BCA0076D1FA /* Project object */ = { 113 | isa = PBXProject; 114 | attributes = { 115 | LastUpgradeCheck = 0930; 116 | ORGANIZATIONNAME = mt; 117 | TargetAttributes = { 118 | 6EF65A1B20B17BCA0076D1FA = { 119 | CreatedOnToolsVersion = 9.3; 120 | }; 121 | }; 122 | }; 123 | buildConfigurationList = 6EF65A1720B17BCA0076D1FA /* Build configuration list for PBXProject "RNDynamicSplash" */; 124 | compatibilityVersion = "Xcode 9.3"; 125 | developmentRegion = en; 126 | hasScannedForEncodings = 0; 127 | knownRegions = ( 128 | en, 129 | ); 130 | mainGroup = 6EF65A1320B17BCA0076D1FA; 131 | productRefGroup = 6EF65A1D20B17BCA0076D1FA /* Products */; 132 | projectDirPath = ""; 133 | projectRoot = ""; 134 | targets = ( 135 | 6EF65A1B20B17BCA0076D1FA /* RNDynamicSplash */, 136 | ); 137 | }; 138 | /* End PBXProject section */ 139 | 140 | /* Begin PBXSourcesBuildPhase section */ 141 | 6EF65A1820B17BCA0076D1FA /* Sources */ = { 142 | isa = PBXSourcesBuildPhase; 143 | buildActionMask = 2147483647; 144 | files = ( 145 | 6EADED5A20C6CC3900D10395 /* FileUtils.m in Sources */, 146 | 6EF65A2120B17BCA0076D1FA /* RNDynamicSplash.m in Sources */, 147 | 6EF65A2920B17E7A0076D1FA /* Utils.m in Sources */, 148 | 6EADED9520C7875D00D10395 /* SplashConfig.m in Sources */, 149 | 6EADED5720C6CC1100D10395 /* HttpUtils.m in Sources */, 150 | ); 151 | runOnlyForDeploymentPostprocessing = 0; 152 | }; 153 | /* End PBXSourcesBuildPhase section */ 154 | 155 | /* Begin XCBuildConfiguration section */ 156 | 6EF65A2320B17BCA0076D1FA /* Debug */ = { 157 | isa = XCBuildConfiguration; 158 | buildSettings = { 159 | ALWAYS_SEARCH_USER_PATHS = NO; 160 | CLANG_ANALYZER_NONNULL = YES; 161 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 162 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; 163 | CLANG_CXX_LIBRARY = "libc++"; 164 | CLANG_ENABLE_MODULES = YES; 165 | CLANG_ENABLE_OBJC_ARC = YES; 166 | CLANG_ENABLE_OBJC_WEAK = YES; 167 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 168 | CLANG_WARN_BOOL_CONVERSION = YES; 169 | CLANG_WARN_COMMA = YES; 170 | CLANG_WARN_CONSTANT_CONVERSION = YES; 171 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 172 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 173 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 174 | CLANG_WARN_EMPTY_BODY = YES; 175 | CLANG_WARN_ENUM_CONVERSION = YES; 176 | CLANG_WARN_INFINITE_RECURSION = YES; 177 | CLANG_WARN_INT_CONVERSION = YES; 178 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 179 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 180 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 181 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 182 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 183 | CLANG_WARN_STRICT_PROTOTYPES = YES; 184 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 185 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 186 | CLANG_WARN_UNREACHABLE_CODE = YES; 187 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 188 | CODE_SIGN_IDENTITY = "iPhone Developer"; 189 | COPY_PHASE_STRIP = NO; 190 | DEBUG_INFORMATION_FORMAT = dwarf; 191 | ENABLE_STRICT_OBJC_MSGSEND = YES; 192 | ENABLE_TESTABILITY = YES; 193 | GCC_C_LANGUAGE_STANDARD = gnu11; 194 | GCC_DYNAMIC_NO_PIC = NO; 195 | GCC_NO_COMMON_BLOCKS = YES; 196 | GCC_OPTIMIZATION_LEVEL = 0; 197 | GCC_PREPROCESSOR_DEFINITIONS = ( 198 | "DEBUG=1", 199 | "$(inherited)", 200 | ); 201 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 202 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 203 | GCC_WARN_UNDECLARED_SELECTOR = YES; 204 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 205 | GCC_WARN_UNUSED_FUNCTION = YES; 206 | GCC_WARN_UNUSED_VARIABLE = YES; 207 | HEADER_SEARCH_PATHS = "$(SRCROOT)/../example/node_modules/react-native/React"; 208 | IPHONEOS_DEPLOYMENT_TARGET = 11.3; 209 | LIBRARY_SEARCH_PATHS = ""; 210 | MTL_ENABLE_DEBUG_INFO = YES; 211 | ONLY_ACTIVE_ARCH = YES; 212 | SDKROOT = iphoneos; 213 | }; 214 | name = Debug; 215 | }; 216 | 6EF65A2420B17BCA0076D1FA /* Release */ = { 217 | isa = XCBuildConfiguration; 218 | buildSettings = { 219 | ALWAYS_SEARCH_USER_PATHS = NO; 220 | CLANG_ANALYZER_NONNULL = YES; 221 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 222 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; 223 | CLANG_CXX_LIBRARY = "libc++"; 224 | CLANG_ENABLE_MODULES = YES; 225 | CLANG_ENABLE_OBJC_ARC = YES; 226 | CLANG_ENABLE_OBJC_WEAK = YES; 227 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 228 | CLANG_WARN_BOOL_CONVERSION = YES; 229 | CLANG_WARN_COMMA = YES; 230 | CLANG_WARN_CONSTANT_CONVERSION = YES; 231 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 232 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 233 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 234 | CLANG_WARN_EMPTY_BODY = YES; 235 | CLANG_WARN_ENUM_CONVERSION = YES; 236 | CLANG_WARN_INFINITE_RECURSION = YES; 237 | CLANG_WARN_INT_CONVERSION = YES; 238 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 239 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 240 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 241 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 242 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 243 | CLANG_WARN_STRICT_PROTOTYPES = YES; 244 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 245 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 246 | CLANG_WARN_UNREACHABLE_CODE = YES; 247 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 248 | CODE_SIGN_IDENTITY = "iPhone Developer"; 249 | COPY_PHASE_STRIP = NO; 250 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 251 | ENABLE_NS_ASSERTIONS = NO; 252 | ENABLE_STRICT_OBJC_MSGSEND = YES; 253 | GCC_C_LANGUAGE_STANDARD = gnu11; 254 | GCC_NO_COMMON_BLOCKS = YES; 255 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 256 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 257 | GCC_WARN_UNDECLARED_SELECTOR = YES; 258 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 259 | GCC_WARN_UNUSED_FUNCTION = YES; 260 | GCC_WARN_UNUSED_VARIABLE = YES; 261 | HEADER_SEARCH_PATHS = "$(SRCROOT)/../example/node_modules/react-native/React"; 262 | IPHONEOS_DEPLOYMENT_TARGET = 11.3; 263 | LIBRARY_SEARCH_PATHS = ""; 264 | MTL_ENABLE_DEBUG_INFO = NO; 265 | SDKROOT = iphoneos; 266 | VALIDATE_PRODUCT = YES; 267 | }; 268 | name = Release; 269 | }; 270 | 6EF65A2620B17BCA0076D1FA /* Debug */ = { 271 | isa = XCBuildConfiguration; 272 | buildSettings = { 273 | CODE_SIGN_STYLE = Automatic; 274 | HEADER_SEARCH_PATHS = "$(inherited)"; 275 | LIBRARY_SEARCH_PATHS = ""; 276 | OTHER_LDFLAGS = "-ObjC"; 277 | PRODUCT_NAME = "$(TARGET_NAME)"; 278 | SKIP_INSTALL = YES; 279 | TARGETED_DEVICE_FAMILY = "1,2"; 280 | }; 281 | name = Debug; 282 | }; 283 | 6EF65A2720B17BCA0076D1FA /* Release */ = { 284 | isa = XCBuildConfiguration; 285 | buildSettings = { 286 | CODE_SIGN_STYLE = Automatic; 287 | HEADER_SEARCH_PATHS = "$(inherited)"; 288 | LIBRARY_SEARCH_PATHS = ""; 289 | OTHER_LDFLAGS = "-ObjC"; 290 | PRODUCT_NAME = "$(TARGET_NAME)"; 291 | SKIP_INSTALL = YES; 292 | TARGETED_DEVICE_FAMILY = "1,2"; 293 | }; 294 | name = Release; 295 | }; 296 | /* End XCBuildConfiguration section */ 297 | 298 | /* Begin XCConfigurationList section */ 299 | 6EF65A1720B17BCA0076D1FA /* Build configuration list for PBXProject "RNDynamicSplash" */ = { 300 | isa = XCConfigurationList; 301 | buildConfigurations = ( 302 | 6EF65A2320B17BCA0076D1FA /* Debug */, 303 | 6EF65A2420B17BCA0076D1FA /* Release */, 304 | ); 305 | defaultConfigurationIsVisible = 0; 306 | defaultConfigurationName = Release; 307 | }; 308 | 6EF65A2520B17BCA0076D1FA /* Build configuration list for PBXNativeTarget "RNDynamicSplash" */ = { 309 | isa = XCConfigurationList; 310 | buildConfigurations = ( 311 | 6EF65A2620B17BCA0076D1FA /* Debug */, 312 | 6EF65A2720B17BCA0076D1FA /* Release */, 313 | ); 314 | defaultConfigurationIsVisible = 0; 315 | defaultConfigurationName = Release; 316 | }; 317 | /* End XCConfigurationList section */ 318 | }; 319 | rootObject = 6EF65A1420B17BCA0076D1FA /* Project object */; 320 | } 321 | -------------------------------------------------------------------------------- /ios/RNDynamicSplash.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /ios/RNDynamicSplash.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /ios/RNDynamicSplash.xcodeproj/project.xcworkspace/xcuserdata/mt.xcuserdatad/UserInterfaceState.xcuserstate: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TaumuLu/react-native-dynamic-splash/a3d368126f8ab1152c29ec0d65a311a8ee8b5593/ios/RNDynamicSplash.xcodeproj/project.xcworkspace/xcuserdata/mt.xcuserdatad/UserInterfaceState.xcuserstate -------------------------------------------------------------------------------- /ios/RNDynamicSplash.xcodeproj/xcuserdata/mt.xcuserdatad/xcschemes/xcschememanagement.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | SchemeUserState 6 | 7 | RNDynamicSplash.xcscheme 8 | 9 | orderHint 10 | 2 11 | 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /ios/Utils/FileUtils.h: -------------------------------------------------------------------------------- 1 | // 2 | // FileUtils.h 3 | // RNDynamicSplash 4 | // 5 | // Created by mt on 2018/6/5. 6 | // Copyright © 2018年 mt. All rights reserved. 7 | // 8 | 9 | #import 10 | #import 11 | 12 | @interface FileUtils : NSObject 13 | 14 | + (UIImage *) getImageFromURL:(NSString *)imageUrl; 15 | + (UIImage *) loadImage:(NSString *)fileName inDirectory:(NSString *)directoryPath; 16 | + (void) saveImage:(UIImage *)image withFileName:(NSString *)imageName inDirectory:(NSString *)directoryPath; 17 | + (NSString *) getImageName:(NSString *)url; 18 | + (NSString *) getLaunchImageName; 19 | 20 | @end 21 | -------------------------------------------------------------------------------- /ios/Utils/FileUtils.m: -------------------------------------------------------------------------------- 1 | // 2 | // FileUtils.m 3 | // RNDynamicSplash 4 | // 5 | // Created by mt on 2018/6/5. 6 | // Copyright © 2018年 mt. All rights reserved. 7 | // 8 | 9 | #import "FileUtils.h" 10 | 11 | @implementation FileUtils 12 | 13 | // 从网络下载图片 14 | + (UIImage *) getImageFromURL:(NSString *)imageUrl { 15 | UIImage *result; 16 | NSData *data = [NSData dataWithContentsOfURL:[NSURL URLWithString:imageUrl]]; 17 | result = [UIImage imageWithData:data]; 18 | 19 | return result; 20 | } 21 | 22 | //读取本地保存的图片 23 | + (UIImage *) loadImage:(NSString *)fileName inDirectory:(NSString *)directoryPath { 24 | NSString *filePath = [NSString stringWithFormat:@"%@/%@.png", directoryPath, fileName]; 25 | UIImage *result = [UIImage imageWithContentsOfFile:filePath]; 26 | 27 | return result; 28 | } 29 | 30 | // 将所下载的图片保存到本地 31 | + (void) saveImage:(UIImage *)image withFileName:(NSString *)imageName inDirectory:(NSString *)directoryPath { 32 | NSString *fileName = [NSString stringWithFormat:@"%@.%@", imageName, @"png"]; 33 | 34 | // 建立文件夹 35 | NSFileManager *fileManager = [NSFileManager defaultManager]; 36 | if(![fileManager fileExistsAtPath:directoryPath]){ 37 | [fileManager createDirectoryAtPath:directoryPath withIntermediateDirectories:YES attributes:nil error:nil]; 38 | } 39 | [UIImagePNGRepresentation(image) writeToFile:[directoryPath stringByAppendingPathComponent:fileName] options:NSAtomicWrite error:nil]; 40 | } 41 | 42 | + (NSString *) getImageName:(NSString *)url { 43 | NSRange range = [url rangeOfString:@"/" options:NSBackwardsSearch]; 44 | return [url substringFromIndex:range.location + 1]; 45 | } 46 | 47 | + (NSString *) getLaunchImageName { 48 | CGSize viewSize = [[UIScreen mainScreen] bounds].size; 49 | // CGSize viewSize = rootView.bounds.size; 50 | // 竖屏 51 | NSString *viewOrientation = @"Portrait"; 52 | NSString *launchImageName = nil; 53 | NSArray* imagesDict = [[[NSBundle mainBundle] infoDictionary] valueForKey:@"UILaunchImages"]; 54 | for (NSDictionary* dict in imagesDict) { 55 | CGSize imageSize = CGSizeFromString(dict[@"UILaunchImageSize"]); 56 | if (CGSizeEqualToSize(imageSize, viewSize) && [viewOrientation isEqualToString:dict[@"UILaunchImageOrientation"]]) 57 | { 58 | launchImageName = dict[@"UILaunchImageName"]; 59 | } 60 | } 61 | 62 | return launchImageName; 63 | } 64 | 65 | @end 66 | -------------------------------------------------------------------------------- /ios/Utils/HttpUtils.h: -------------------------------------------------------------------------------- 1 | // 2 | // HttpUtils.h 3 | // RNDynamicSplash 4 | // 5 | // Created by mt on 2018/6/5. 6 | // Copyright © 2018年 mt. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | typedef void (^getCallBack)(NSData *data); 12 | 13 | @interface HttpUtils : NSObject 14 | 15 | + (void)get:(NSString *)url callback:(getCallBack)callback; 16 | 17 | @end 18 | -------------------------------------------------------------------------------- /ios/Utils/HttpUtils.m: -------------------------------------------------------------------------------- 1 | // 2 | // HttpUtils.m 3 | // RNDynamicSplash 4 | // 5 | // Created by mt on 2018/6/5. 6 | // Copyright © 2018年 mt. All rights reserved. 7 | // 8 | 9 | #import "HttpUtils.h" 10 | 11 | @implementation HttpUtils 12 | 13 | + (void) get:(NSString *)urlString callback:(getCallBack)callback { 14 | NSURL *url = [NSURL URLWithString:urlString]; 15 | NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:url cachePolicy:NSURLRequestUseProtocolCachePolicy timeoutInterval:60.0]; 16 | 17 | [NSURLConnection sendAsynchronousRequest:request queue:[NSOperationQueue mainQueue] completionHandler:^(NSURLResponse *response, NSData *data, NSError *connectionError) { 18 | callback(data); 19 | }]; 20 | } 21 | 22 | // + (void)getExample { 23 | // NSString *urlString = [[NSString alloc] initWithFormat:@"%@%@%@", agreement, domain, requestURL]; 24 | // [Utils get:urlString callback:^(NSData *data) { 25 | // if(data != nil) { 26 | // NSDictionary *dict = [NSJSONSerialization JSONObjectWithData:data options:NSJSONReadingMutableLeaves error:nil]; 27 | // NSDictionary *info = dict[@"app.startup.img"]; 28 | // NSString *value = info[@"value"]; 29 | 30 | // if(![Utils isBlankString: value]) { 31 | // NSData *valueData = [value dataUsingEncoding:NSUTF8StringEncoding]; 32 | // NSDictionary *valueDict = [NSJSONSerialization JSONObjectWithData:valueData options:NSJSONReadingMutableLeaves error:nil]; 33 | // NSString *imgUrl = [valueDict[@"img"] substringFromIndex:2]; 34 | // // 获得NSUserDefaults文件 35 | // NSUserDefaults *userDefaults = [NSUserDefaults standardUserDefaults]; 36 | // NSString *splashConfig = [userDefaults objectForKey:userDefaultsKey]; 37 | // NSString *imgName = [self getImageName:imgUrl]; 38 | // if(![splashConfig isEqualToString:imgName]) { 39 | // NSString *imageUrl = [[NSString alloc] initWithFormat:@"%@%@", agreement, imgUrl]; 40 | // [self downloadImage:imageUrl]; 41 | // } 42 | // [userDefaults setObject:imgName forKey:userDefaultsKey]; 43 | // } 44 | // } 45 | // }]; 46 | // } 47 | 48 | @end 49 | -------------------------------------------------------------------------------- /ios/Utils/SplashConfig.h: -------------------------------------------------------------------------------- 1 | // 2 | // SplashConfig.h 3 | // RNDynamicSplash 4 | // 5 | // Created by mt on 2018/6/6. 6 | // Copyright © 2018年 mt. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface SplashConfig : NSObject 12 | 13 | @property NSString *imageUrl; 14 | @property NSString *splashSavePath; 15 | @property bool autoDownload; 16 | @property bool dynamicShow; 17 | @property bool autoHide; 18 | @property int autoHideTime; 19 | 20 | @end 21 | -------------------------------------------------------------------------------- /ios/Utils/SplashConfig.m: -------------------------------------------------------------------------------- 1 | // 2 | // SplashConfig.m 3 | // RNDynamicSplash 4 | // 5 | // Created by mt on 2018/6/6. 6 | // Copyright © 2018年 mt. All rights reserved. 7 | // 8 | 9 | #import "SplashConfig.h" 10 | 11 | @implementation SplashConfig 12 | 13 | - (instancetype)init { 14 | if (self = [super init]) { 15 | self.imageUrl = @""; 16 | self.splashSavePath = @"/splash/"; 17 | self.autoDownload = true; 18 | self.dynamicShow = true; 19 | self.autoHide = false; 20 | self.autoHideTime = 3000; 21 | } 22 | return self; 23 | } 24 | 25 | @end 26 | -------------------------------------------------------------------------------- /ios/Utils/Utils.h: -------------------------------------------------------------------------------- 1 | // 2 | // Utils.h 3 | // RNDynamicSplash 4 | // 5 | // Created by mt on 2018/5/20. 6 | // Copyright © 2018年 mt. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | @interface Utils : NSObject 12 | 13 | + (BOOL)isBlankString:(NSString *)str; 14 | 15 | @end 16 | -------------------------------------------------------------------------------- /ios/Utils/Utils.m: -------------------------------------------------------------------------------- 1 | // 2 | // Utils.m 3 | // RNDynamicSplash 4 | // 5 | // Created by mt on 2018/5/20. 6 | // Copyright © 2018年 mt. All rights reserved. 7 | // 8 | 9 | #import "Utils.h" 10 | 11 | @implementation Utils 12 | 13 | + (BOOL)isBlankString:(NSString *)str { 14 | NSString *string = str; 15 | if (string == nil || string == NULL) { 16 | return YES; 17 | } 18 | if ([string isKindOfClass:[NSNull class]]) { 19 | return YES; 20 | } 21 | if ([[string stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]] length]==0) { 22 | return YES; 23 | } 24 | 25 | return NO; 26 | } 27 | 28 | @end 29 | -------------------------------------------------------------------------------- /package-lock.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "react-native-dynamic-splash", 3 | "version": "1.1.2", 4 | "lockfileVersion": 1 5 | } 6 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "react-native-dynamic-splash", 3 | "version": "1.1.2", 4 | "description": "dynamic display splash", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "TaumuLu", 10 | "license": "ISC", 11 | "keywords": [ 12 | "react-native", 13 | "splash", 14 | "advertising screen", 15 | "dynamic", 16 | "download" 17 | ], 18 | "repository": { 19 | "type": "git", 20 | "url": "git+https://github.com/TaumuLu/react-native-dynamic-splash.git" 21 | }, 22 | "bugs": { 23 | "url": "https://github.com/TaumuLu/react-native-dynamic-splash/issues" 24 | }, 25 | "homepage": "https://github.com/TaumuLu/react-native-dynamic-splash#readme" 26 | } 27 | --------------------------------------------------------------------------------