Some scene will need to transition to others on their own for user experience purposes. In this video, learn how to use a timer and lifecycle hooks to implement a splash scene.
- [Instructor] Previously we made a side menu.…Now let's add our splash screen.…Under app, let's make a new folder called scenes.…In that folder, we'll make a new file;…and we'll call it SplashScene.js.…In this file, the first thing we're going to do…is import React and component from react.…Next we need to import image from react-native,…and we'll import View from native-base.…
Now we can go ahead and make our class.…So we'll export default class SplashScene,…and that's going to extend component.…Now in our constructor, we'll take in properties…and we'll pass those properties up to super.…Next let's override a react lifecycle hook…called componentDidMount.…This is called every time a component mounts…onto the React virtual DOM.…First thing we're going to do in there…is create a constant variable called stores.…
We're going to use the ES6 syntax…to pull it out of our properties,…so this.props; then we'll call setTimeout…to create a timer for our splash screen.…This takes in an anonymous function;…and in that function, we're going to make use…
- Setting up your project and Firebase account
- Creating the app container
- Setting up basic navigation
- Creating a splash screen
- Creating a login screen
- Creating a match feature
- Creating a post feature
Skill Level Intermediate
Building an App with React.js and MeteorJSwith Emmanuel Henri4h 20m Intermediate
Building a Web Interface with React.jswith Ray Villalobos1h 21m Intermediate
1. Getting Set Up
2. Building an App
3. Create a Login Screen
4. Create a Match Feature
5. Create a Post Feature
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.