Skip to content

Commit 602db9f

Browse files
committed
refactor(example): migrate example to RN v0.44.3 and plugin v2.2.0
1 parent bde4b65 commit 602db9f

File tree

9 files changed

+3424
-1604
lines changed

9 files changed

+3424
-1604
lines changed

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* Implement vertical mode (prop `vertical`)
33
* Make sure that current active item is properly updated when snapping
44
* Prevent issues when 'sliderWidth' is smaller than viewport's width
5-
* Recalculate card positions on layout to handle rotation (thanks [@andrewpope](https://github.com/andrewpope)); make sure to read [this note] (https://github.com/archriss/react-native-snap-carousel#handling-device-rotation)
5+
* Recalculate card positions on layout to handle rotation (thanks [@andrewpope](https://github.com/andrewpope)); make sure to read [this note](https://github.com/archriss/react-native-snap-carousel#handling-device-rotation)
66
* Refresh card positions if slider and/or item's dimensions are updated (thanks [@hoangnm](https://github.com/hoangnm))
77
* Add props `scrollEndDragThrottleValue` and `snapCallbackDebounceValue`
88
* Expose `View`'s `onLayout` prop

example/.babelrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
"presets": ["react-native"]
2+
"presets": ["react-native"]
33
}

example/.flowconfig

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,12 +36,12 @@ suppress_type=$FlowIssue
3636
suppress_type=$FlowFixMe
3737
suppress_type=$FixMe
3838

39-
suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(>=0\\.\\(4[0-0]\\|[1-3][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)
40-
suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(>=0\\.\\(4[0-0]\\|[1-3][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+
39+
suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(>=0\\.\\(4[0-2]\\|[1-3][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)
40+
suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(>=0\\.\\(4[0-2]\\|[1-3][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+
4141
suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy
4242
suppress_comment=\\(.\\|\n\\)*\\$FlowExpectedError
4343

4444
unsafe.enable_getters_and_setters=true
4545

4646
[version]
47-
^0.40.0
47+
^0.42.0

example/android/app/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ import com.android.build.OutputFile
5858
* inputExcludes: ["android/**", "ios/**"],
5959
*
6060
* // override which node gets called and with what additional arguments
61-
* nodeExecutableAndArgs: ["node"]
61+
* nodeExecutableAndArgs: ["node"],
6262
*
6363
* // supply additional arguments to the packager
6464
* extraPackagerArgs: []

example/android/app/proguard-rules.pro

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,10 @@
5050

5151
-dontwarn com.facebook.react.**
5252

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+
5357
# okhttp
5458

5559
-keepattributes Signature

example/ios/exampleTests/exampleTests.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ - (BOOL)findSubviewInView:(UIView *)view matching:(BOOL(^)(UIView *view))test
3737

3838
- (void)testRendersWelcomeScreen
3939
{
40-
UIViewController *vc = [[[[UIApplication sharedApplication] delegate] window] rootViewController];
40+
UIViewController *vc = [[[RCTSharedApplication() delegate] window] rootViewController];
4141
NSDate *date = [NSDate dateWithTimeIntervalSinceNow:TIMEOUT_SECONDS];
4242
BOOL foundElement = NO;
4343

0 commit comments

Comments
 (0)