mirror of
https://github.com/zhigang1992/react-navigation.git
synced 2026-02-10 09:13:43 +08:00
move to react-nav core and native deps
This commit is contained in:
committed by
satyajit.happy
parent
21a6b66f09
commit
ae4c0b8a35
@@ -1,10 +1,7 @@
|
||||
import React from 'react';
|
||||
import { Dimensions, Platform, ScrollView } from 'react-native';
|
||||
import {
|
||||
createNavigator,
|
||||
createNavigationContainer,
|
||||
SafeAreaView,
|
||||
} from 'react-navigation';
|
||||
import { createNavigator } from '@react-navigation/core';
|
||||
import { SafeAreaView } from '@react-navigation/native';
|
||||
import DrawerRouter from '../routers/DrawerRouter';
|
||||
import DrawerView from '../views/DrawerView';
|
||||
import DrawerItems from '../views/DrawerNavigatorItems';
|
||||
@@ -51,7 +48,7 @@ const DrawerNavigator = (routeConfigs, config = {}) => {
|
||||
const mergedConfig = { ...DefaultDrawerConfig, ...config };
|
||||
const drawerRouter = DrawerRouter(routeConfigs, mergedConfig);
|
||||
const navigator = createNavigator(DrawerView, drawerRouter, mergedConfig);
|
||||
return createNavigationContainer(navigator);
|
||||
return navigator;
|
||||
};
|
||||
|
||||
export default DrawerNavigator;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import React from 'react';
|
||||
import { View, Text, StyleSheet } from 'react-native';
|
||||
import { SafeAreaView } from 'react-navigation';
|
||||
import { SafeAreaView } from '@react-navigation/native';
|
||||
import TouchableItem from './TouchableItem';
|
||||
|
||||
/**
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import React from 'react';
|
||||
import { StyleSheet, View } from 'react-native';
|
||||
|
||||
import { NavigationActions, StackActions } from 'react-navigation';
|
||||
import { NavigationActions, StackActions } from '@react-navigation/core';
|
||||
import invariant from '../utils/invariant';
|
||||
|
||||
/**
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import React from 'react';
|
||||
import { Dimensions } from 'react-native';
|
||||
import { SceneView } from 'react-navigation';
|
||||
import { SceneView } from '@react-navigation/core';
|
||||
import DrawerActions from '../routers/DrawerActions';
|
||||
import DrawerLayout from './DrawerLayout';
|
||||
import DrawerSidebar from './DrawerSidebar';
|
||||
|
||||
Reference in New Issue
Block a user