From f99acd4d73a457ec7dfa5eb7d6ebdca3cc33b26d Mon Sep 17 00:00:00 2001 From: bd-arc Date: Thu, 23 Mar 2017 19:18:58 +0100 Subject: [PATCH] refactor(example): fix applicationId and bump RN version to 0.42.3 --- example/.flowconfig | 8 ++++--- example/.gitignore | 1 - example/android/app/build.gradle | 2 +- .../android/app/src/main/AndroidManifest.xml | 3 ++- .../java/com/example/MainApplication.java | 2 -- example/android/build.gradle | 2 +- .../gradle/wrapper/gradle-wrapper.properties | 2 +- example/package.json | 2 +- example/src/index.js | 6 ++++- example/yarn.lock | 23 +++++++------------ 10 files changed, 24 insertions(+), 27 deletions(-) diff --git a/example/.flowconfig b/example/.flowconfig index b38ea97e1..581be5fe4 100644 --- a/example/.flowconfig +++ b/example/.flowconfig @@ -22,6 +22,8 @@ node_modules/react-native/flow flow/ [options] +emoji=true + module.system=haste experimental.strict_type_args=true @@ -34,11 +36,11 @@ suppress_type=$FlowIssue suppress_type=$FlowFixMe suppress_type=$FixMe -suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(>=0\\.\\(3[0-7]\\|[1-2][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\) -suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(>=0\\.\\(3[0-7]\\|1[0-9]\\|[1-2][0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+ +suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(>=0\\.\\(3[0-8]\\|[1-2][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\) +suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(>=0\\.\\(3[0-8]\\|1[0-9]\\|[1-2][0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+ suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy unsafe.enable_getters_and_setters=true [version] -^0.37.0 +^0.38.0 \ No newline at end of file diff --git a/example/.gitignore b/example/.gitignore index 8fce63971..10be19751 100644 --- a/example/.gitignore +++ b/example/.gitignore @@ -39,7 +39,6 @@ yarn-error.log # BUCK buck-out/ \.buckd/ -android/app/libs *.keystore # fastlane diff --git a/example/android/app/build.gradle b/example/android/app/build.gradle index 1f030d9b7..1dad1044c 100644 --- a/example/android/app/build.gradle +++ b/example/android/app/build.gradle @@ -87,7 +87,7 @@ android { buildToolsVersion "23.0.1" defaultConfig { - applicationId "fr.archriss.example.snap.carousel" + applicationId "com.example" minSdkVersion 16 targetSdkVersion 22 versionCode 1 diff --git a/example/android/app/src/main/AndroidManifest.xml b/example/android/app/src/main/AndroidManifest.xml index 677f07596..8275835d5 100644 --- a/example/android/app/src/main/AndroidManifest.xml +++ b/example/android/app/src/main/AndroidManifest.xml @@ -19,7 +19,8 @@ + android:configChanges="keyboard|keyboardHidden|orientation|screenSize" + android:windowSoftInputMode="adjustResize"> diff --git a/example/android/app/src/main/java/com/example/MainApplication.java b/example/android/app/src/main/java/com/example/MainApplication.java index f7a3def5b..f51721bb8 100644 --- a/example/android/app/src/main/java/com/example/MainApplication.java +++ b/example/android/app/src/main/java/com/example/MainApplication.java @@ -1,10 +1,8 @@ package com.example; import android.app.Application; -import android.util.Log; import com.facebook.react.ReactApplication; -import com.facebook.react.ReactInstanceManager; import com.facebook.react.ReactNativeHost; import com.facebook.react.ReactPackage; import com.facebook.react.shell.MainReactPackage; diff --git a/example/android/build.gradle b/example/android/build.gradle index fcba4c587..eed9972b5 100644 --- a/example/android/build.gradle +++ b/example/android/build.gradle @@ -5,7 +5,7 @@ buildscript { jcenter() } dependencies { - classpath 'com.android.tools.build:gradle:1.3.1' + classpath 'com.android.tools.build:gradle:2.2.3' // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files diff --git a/example/android/gradle/wrapper/gradle-wrapper.properties b/example/android/gradle/wrapper/gradle-wrapper.properties index b9fbfaba0..dbdc05d27 100644 --- a/example/android/gradle/wrapper/gradle-wrapper.properties +++ b/example/android/gradle/wrapper/gradle-wrapper.properties @@ -2,4 +2,4 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-2.4-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-2.14.1-all.zip diff --git a/example/package.json b/example/package.json index d9a3a9441..581e163f9 100644 --- a/example/package.json +++ b/example/package.json @@ -8,7 +8,7 @@ }, "dependencies": { "react": "15.4.2", - "react-native": "0.41.2", + "react-native": "0.42.3", "react-native-snap-carousel": "file:.." }, "devDependencies": { diff --git a/example/src/index.js b/example/src/index.js index 5ef336657..efd6144cc 100644 --- a/example/src/index.js +++ b/example/src/index.js @@ -69,7 +69,11 @@ export default class example extends Component { render () { return ( - + diff --git a/example/yarn.lock b/example/yarn.lock index d16e31094..dca49e736 100644 --- a/example/yarn.lock +++ b/example/yarn.lock @@ -893,18 +893,12 @@ browser-resolve@^1.11.2: dependencies: resolve "1.1.7" -bser@1.0.2: +bser@1.0.2, bser@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/bser/-/bser-1.0.2.tgz#381116970b2a6deea5646dd15dd7278444b56169" dependencies: node-int64 "^0.4.0" -bser@^1.0.2: - version "1.0.3" - resolved "https://registry.yarnpkg.com/bser/-/bser-1.0.3.tgz#d63da19ee17330a0e260d2a34422b21a89520317" - dependencies: - node-int64 "^0.4.0" - bser@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/bser/-/bser-2.0.0.tgz#9ac78d3ed5d915804fd87acb158bc797147a1719" @@ -2871,13 +2865,13 @@ mime-db@~1.23.0: version "1.23.0" resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.23.0.tgz#a31b4070adaea27d732ea333740a64d0ec9a6659" -mime-types@2.1.11, mime-types@~2.1.7, mime-types@~2.1.9: +mime-types@2.1.11, mime-types@~2.1.7: version "2.1.11" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.11.tgz#c259c471bda808a85d6cd193b430a5fae4473b3c" dependencies: mime-db "~1.23.0" -mime-types@^2.1.12, mime-types@~2.1.11, mime-types@~2.1.13, mime-types@~2.1.6: +mime-types@^2.1.12, mime-types@~2.1.11, mime-types@~2.1.13, mime-types@~2.1.6, mime-types@~2.1.9: version "2.1.14" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.14.tgz#f7ef7d97583fcaf3b7d282b6f8b5679dab1e94ee" dependencies: @@ -3311,15 +3305,14 @@ react-deep-force-update@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/react-deep-force-update/-/react-deep-force-update-1.0.1.tgz#f911b5be1d2a6fe387507dd6e9a767aa2924b4c7" -react-native-snap-carousel@2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/react-native-snap-carousel/-/react-native-snap-carousel-2.0.1.tgz#c8c720365a8beea7ed9ebf0b2d278adf614c5a9c" +"react-native-snap-carousel@file:..": + version "2.0.2" dependencies: react-addons-shallow-compare latest -react-native@0.41.2: - version "0.41.2" - resolved "https://registry.yarnpkg.com/react-native/-/react-native-0.41.2.tgz#c6f486b8450a9909e6fed2dfd2c2af946563bf4f" +react-native@0.42.3: + version "0.42.3" + resolved "https://registry.yarnpkg.com/react-native/-/react-native-0.42.3.tgz#450c8a03a5e3e991a08a426f22776dd8feb80b26" dependencies: absolute-path "^0.0.0" art "^0.10.0"