Skip to content
This repository was archived by the owner on Feb 25, 2020. It is now read-only.

Commit 8cc9069

Browse files
committed
fix: add peer dep on react-navigation
1 parent cc37ff4 commit 8cc9069

25 files changed

+74
-121
lines changed

.eslintrc

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,15 @@
55

66
"env": {
77
"es6": true,
8-
"react-native-globals/all": true,
8+
"react-native-globals/all": true
9+
},
10+
11+
"settings": {
12+
"import/core-modules": ["react-native-screens"]
913
},
1014

1115
"rules": {
12-
"import/no-unresolved": "off",
16+
"import/named": "off",
1317
"react-native/no-inline-styles": "off"
1418
}
1519
}

example/App.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,12 @@
11
import * as React from 'react';
22
// eslint-disable-next-line no-unused-vars
33
import { View, TouchableOpacity, FlatList, I18nManager } from 'react-native';
4-
import { ThemeContext, ThemeColors } from '@react-navigation/core';
5-
import { Themed, createAppContainer } from '@react-navigation/native';
4+
import {
5+
ThemeContext,
6+
ThemeColors,
7+
Themed,
8+
createAppContainer,
9+
} from 'react-navigation';
610
import { createStackNavigator } from 'react-navigation-stack';
711
import { MaterialCommunityIcons } from '@expo/vector-icons';
812
import { List, Divider } from 'react-native-paper';

example/metro.config.js

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,6 @@ module.exports = {
2222
providesModuleNodeModules: [
2323
'@expo/vector-icons',
2424
'@babel/runtime',
25-
'@react-navigation/core',
26-
'@react-navigation/native',
27-
'react-native-gesture-handler',
28-
'react-native-reanimated',
2925
...dependencies,
3026
...peerDependencies,
3127
],

example/package.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,6 @@
1010
},
1111
"dependencies": {
1212
"@expo/vector-icons": "^10.0.0",
13-
"@react-navigation/core": "^3.5.0",
14-
"@react-navigation/native": "^3.6.0",
1513
"expo": "^34.0.0",
1614
"expo-asset": "^6.0.0",
1715
"expo-constants": "~6.0.0",
@@ -22,6 +20,7 @@
2220
"react-native-paper": "^2.2.0",
2321
"react-native-reanimated": "~1.1.0",
2422
"react-native-webview": "~5.12.0",
23+
"react-navigation": "^4.0.1",
2524
"react-navigation-stack": "^1.4.0"
2625
},
2726
"devDependencies": {

example/src/GestureInteraction.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import * as React from 'react';
22
import { Button, View } from 'react-native';
3-
import { withNavigation } from '@react-navigation/core';
3+
import { withNavigation } from 'react-navigation';
44
import {
55
createDrawerNavigator,
66
DrawerGestureContext,

example/src/ParallaxDrawer.js

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,11 @@ import {
77
StyleSheet,
88
View,
99
} from 'react-native';
10-
10+
import { ThemeColors, useTheme, Themed, SafeAreaView } from 'react-navigation';
1111
import { createStackNavigator } from 'react-navigation-stack';
12-
import { ThemeColors, useTheme } from '@react-navigation/core';
13-
import { Themed, SafeAreaView } from '@react-navigation/native';
14-
import MaterialIcons from 'react-native-vector-icons/MaterialIcons';
15-
import Animated from 'react-native-reanimated';
1612
import { createDrawerNavigator } from 'react-navigation-drawer';
13+
import Animated from 'react-native-reanimated';
14+
import { MaterialIcons } from '@expo/vector-icons';
1715

1816
const SampleText = ({ children }) => <Themed.Text>{children}</Themed.Text>;
1917

example/src/RTLDrawer.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import {
77
TouchableOpacity,
88
} from 'react-native';
99

10-
import { Themed } from '@react-navigation/native';
10+
import { Themed } from 'react-navigation';
1111
import { createStackNavigator } from 'react-navigation-stack';
1212
import { createDrawerNavigator } from 'react-navigation-drawer';
1313

example/src/SimpleDrawer.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
import React from 'react';
22
import { Button, ScrollView, StyleSheet, View } from 'react-native';
33
import { createStackNavigator } from 'react-navigation-stack';
4-
import { ThemeColors, useTheme } from '@react-navigation/core';
5-
import { Themed, SafeAreaView } from '@react-navigation/native';
6-
import MaterialIcons from 'react-native-vector-icons/MaterialIcons';
4+
import { ThemeColors, useTheme, Themed, SafeAreaView } from 'react-navigation';
75
import { createDrawerNavigator } from 'react-navigation-drawer';
6+
import { MaterialIcons } from '@expo/vector-icons';
87

98
const SampleText = ({ children }) => <Themed.Text>{children}</Themed.Text>;
109

example/src/StyledDrawer.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
import React from 'react';
22
import { Button, ScrollView } from 'react-native';
33
import { createStackNavigator } from 'react-navigation-stack';
4-
import { Themed, SafeAreaView } from '@react-navigation/native';
5-
import MaterialIcons from 'react-native-vector-icons/MaterialIcons';
4+
import { Themed, SafeAreaView } from 'react-navigation';
65
import { createDrawerNavigator } from 'react-navigation-drawer';
6+
import { MaterialIcons } from '@expo/vector-icons';
77

88
const SampleText = ({ children }) => <Themed.Text>{children}</Themed.Text>;
99

example/yarn.lock

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -918,7 +918,7 @@
918918
query-string "^6.4.2"
919919
react-is "^16.8.6"
920920

921-
"@react-navigation/native@^3.6.0":
921+
"@react-navigation/native@^3.6.2":
922922
version "3.6.2"
923923
resolved "https://registry.yarnpkg.com/@react-navigation/native/-/native-3.6.2.tgz#3634697b6350cc5189657ae4551f2d52b57fbbf0"
924924
integrity sha512-Cybeou6N82ZeRmgnGlu+wzlV3z5BZQR2dmYaNFV1TNLUGHqtvv8E7oNw9uYcz9Ox5LFbiX+FdNTn2d6ZPlK0kg==
@@ -4352,9 +4352,9 @@ react-native-safe-area-view@^0.12.0:
43524352
hoist-non-react-statics "^2.3.1"
43534353

43544354
react-native-safe-area-view@^0.14.1:
4355-
version "0.14.7"
4356-
resolved "https://registry.yarnpkg.com/react-native-safe-area-view/-/react-native-safe-area-view-0.14.7.tgz#e1dd1c4d25a90677df2c15347fdddb2306ba5971"
4357-
integrity sha512-fmuBYpvKDJK33bimo4JXrK2BN2CGw7nof1y1LDRgzqv+FZ3eADSDGshprN8WeQqSZjQ20hJx1CiWk28Edg/v4Q==
4355+
version "0.14.8"
4356+
resolved "https://registry.yarnpkg.com/react-native-safe-area-view/-/react-native-safe-area-view-0.14.8.tgz#ef33c46ff8164ae77acad48c3039ec9c34873e5b"
4357+
integrity sha512-MtRSIcZNstxv87Jet+UsPhEd1tpGe8cVskDXlP657x6rHpSrbrc+y13ZNXrwAgGNNhqQNX7UJT68ZIq//ZRmvw==
43584358
dependencies:
43594359
hoist-non-react-statics "^2.3.1"
43604360

@@ -4440,6 +4440,14 @@ react-navigation-stack@^1.4.0:
44404440
dependencies:
44414441
prop-types "^15.7.2"
44424442

4443+
react-navigation@^4.0.1:
4444+
version "4.0.1"
4445+
resolved "https://registry.yarnpkg.com/react-navigation/-/react-navigation-4.0.1.tgz#96c17ac90afcf0a5bc957358152326211a79d183"
4446+
integrity sha512-6XzuqvhOnY6FA6tCErD6+vfZdnP+O/7hCQper9qDulxxW2ZVkCF4xWdzoVcv3DDR6P5CK6l1tcbJ1ku256AdFQ==
4447+
dependencies:
4448+
"@react-navigation/core" "^3.5.0"
4449+
"@react-navigation/native" "^3.6.2"
4450+
44434451
react-proxy@^1.1.7:
44444452
version "1.1.8"
44454453
resolved "https://registry.yarnpkg.com/react-proxy/-/react-proxy-1.1.8.tgz#9dbfd9d927528c3aa9f444e4558c37830ab8c26a"

0 commit comments

Comments
 (0)