How To Make A Splash Screen Efficiently
Solution 1:
As much as possible avoid having a splash in your app. As an app user I also have this behavior.
- I really need to use the App immediately because time is precious.
- I have limited patience (probably most people will agree).
- I don't need it at all.
So what if we can't totally avoid having a splash screen? The suggested concept that I gather are these:
Lazy Loading - Load only those piece of information that is really needed by now. Example : A Movie app: Load only those latest movies rather than those old movies unless the user told you to do so. The idea here is that decided only on which is necessary to load first and load other else later on. With this approached you lessen the time showing your splash screen.
Caching - If you keep on downloading things from your server chances are it might take too long to load and your splash screen will be visible for longer period of time. With caching you will need to fetch fewer data from the network since you've downloaded some of them already.
Things to consider in creating views.
- Avoid a super deep nested views.
- Avoid a deep nested weights.
- For image loading use some popular library like Picasso, Glide etc.
Solution 2:
1.Make a new activity with a layout and show that activity for some time.But making another activity with a layout makes the app heavy.
While making the activity, you use Thread to show the splash screen. Make the Activity thread sleep for few seconds and update background data during sleep is efficient.
Post a Comment for "How To Make A Splash Screen Efficiently"