This repository has been archived by the owner on Mar 8, 2023. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added more scenes and Splash auto navigation
- Loading branch information
Konrad Abe
committed
Feb 16, 2020
1 parent
71d4194
commit e2ea784
Showing
2 changed files
with
31 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,25 @@ | ||
import React from 'react' | ||
import React, { useEffect } from 'react' | ||
import { Text } from 'react-native' | ||
import PropTypes from 'prop-types' | ||
import DefaultPage from '../../components/DefaultPage' | ||
|
||
const SceneSplash = () => ( | ||
<DefaultPage> | ||
<Text> | ||
Splash | ||
</Text> | ||
</DefaultPage> | ||
) | ||
const SceneSplash = ({ navigation }) => { | ||
useEffect(() => { | ||
setTimeout(() => { | ||
navigation.navigate('AppLoading') | ||
}, 2000) | ||
}, []) | ||
return ( | ||
<DefaultPage> | ||
<Text> | ||
Splash | ||
</Text> | ||
</DefaultPage> | ||
) | ||
} | ||
|
||
SceneSplash.propTypes = { | ||
navigation: PropTypes.object.isRequired, | ||
} | ||
|
||
export default SceneSplash |