Fireship · @fireship
Custom Ionic Splash + Animation
Uploaded February 19, 2018 · Length 5:29
Summary
Create a custom Ionic splash screen with animation, including generating graphics and adding CSS animation.
- ionic splash screen
- custom animation
- cordova resources
- css animation
- native mobile apps
- ionic development
Transcript preview
The first 2 minutes of the transcript. Select a timestamp to watch that moment on YouTube.
- 0:00
[Music]
- 0:02
almost all good native mobile apps have
- 0:04
one thing in common and that's a
- 0:06
high-quality loading page when you enter
- 0:08
the app for the first time in this
- 0:10
episode I'm going to show you how to
- 0:11
build your own high-quality splash
- 0:12
graphics with ionic we're going to make
- 0:15
sure the graphics and the animation look
- 0:16
good on both iOS and Android and I'm
- 0:19
going to take a different approach than
- 0:20
other tutorials out there have taken
- 0:22
most importantly I want to show you how
- 0:24
to avoid this ugly white page if you're
- 0:26
using animations in your splash page hit
- 0:29
subscribe if you're new and follow along
- 0:30
with the source code at angular firebase
- 0:32
comm I am starting out from a brand new
- 0:35
ionic app and using the side menu
- 0:37
starter template before we do anything
- 0:39
with animation I first want to show you
- 0:41
how to generate an app icon and static
- 0:43
splash page from the command line start
- 0:46
by going into the resources directory
- 0:47
and delete the icon and splash PNG files
- 0:51
then you'll need to generate your own
- 0:53
graphics and something like Photoshop or
- 0:55
sketch the app icon needs to be at least
- 0:58
a thousand 24 pixels and the splash page
- 1:00
needs to be at least 2732 pixels
- 1:04
once you have those created you can just
- 1:06
go ahead and save them back in the
- 1:07
resources directory with the same name
- 1:09
splash and icon from there we can
- 1:12
generate all of the icons we need for
- 1:14
every single device on a given platform
- 1:16
all you need to do is run I on it
- 1:18
Cordova resources from the command line
- 1:20
and it's going to do everything else for
- 1:22
you this takes your source images and
- 1:25
resizes them so they look good on the
- 1:27
iPad iPhone and other mobile devices you
- 1:30
can see the results by going under the
- 1:32
platform directory under resources and
- 1:34
looking at all the generated graphics if
- 1:37
you open your app on a native emulator
- 1:39
you should see the custom graphic as
- 1:40
well as the custom splash screen that
- 1:43
looks pretty cool and is probably enough
- 1:45
for most apps but I still want to show
- 1:47
you how to take things a step further by
- 1:48
adding your own custom animation the
- 1:51
easiest strategy in my opinion is to use
- 1:53
a CSS animation but you could also use
- 1:55
JavaScript here as well to keep things
- 1:58
simple I'm going to use a pre-built
- 1:59
open source animation but you could


