A presentation at Bristol Web Performance Meetup in July 2016 in Bristol, UK by Simon Hearne
WE’RE BREAKING THE MOBILE WEB
Aw, Snap!
@SimonHearne | We’re breaking the mobile web | Bristol Web Performance Meetup
Simon Hearne
@SimonHearne
Senior Performance Consultant
NCC Group
a brief history of
web performance
Sept 21 st
2007
web performance was ‘invented’
my phone
in 2007
web performance was invented
Loading Web Sites
Because in 2007, developers didn’t get it
“optimisation” was done on the server
because the application was on the server
even web2.0 was pretty static
May 13 th
2013
I started work in web performance
My induction…
LIFE WAS EASY
“Reduce blocking JavaScript”
“Use gzip
compression”
“Compress images”
“Reduce TTFB”
…
but the way we consume the web has changed
2016
and the way we develop for the web has changed
0% 10% 20% 30% 40% 50% 60% 70% 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 Non-Desktop Traffic Single Page Apps
Solution:
Responsive Web Design
”
“
Responsive
web design
is
a
fluid grid , flexible
images
and media queries
Ethan Marcotte
i.e.
cram
a desktop site
into
a mobile
viewport
Unless
your
site
an
application
Which
fine.
w e
increasingly
rely
on
JavaScript,
w hile
our
users
use mobile
devices
Among our 5,400 panelists , approximately
enabled devices.
2/#javascript
Website visitors tend to
care more about speed
than all the bells and whistles
we want to add to our websites
KISS Metrics
mobile web = web
Mobile applications
are a bridging
technology .
Like
Flash.
Bruce Lawson
people would rather uninstall an app than delete photos
SELECT COUNT(*) FROM [ httparchive:runs.latest_requests_mobile ] WHERE firstHtml
IS TRUE AND url
like "%://m.%"
85%
of websites are ‘responsive’
SELECT COUNT(DISTINCT pageid ) FROM [ httparchive:runs.latest_requests_mobile ] WHERE url
LIKE "% modernizr %"
11%
of mobile pages use Modernizr
SELECT COUNT(DISTINCT pageid ) FROM [ httparchive:runs.latest_requests_mobile ] WHERE
url
LIKE "% angular%" OR url
LIKE "%react%" OR url
LIKE "%ember%" OR url
LIKE "%meteor%"
10 %
of mobile pages are SPAs
LIKE "% optimizely %" or url
LIKE "% maxymiser %" or url
LIKE "% zarget %" or url
LIKE "% visualwebsiteoptimizer %"
10%
of mobile pages have A/B testing
http://mobile.httparchive.org/trends.php#bytesJS&reqJS
422kB
average
mobile JS payload
mobile web = slow
In the beginning, there was the network
the U.K. ranks near the bottom
of the list of 4G countries in terms of coverage
Open Signal
State of Mobile Networks 2016
then there was the cheap device
poor/33889
desktop JavaScript performance on mobile devices.
That is clearly happening on iOS
but it is quite disastrously the opposite on Android.
iOS
~3s
Android
~6s
Android is consistently ~two times slower than iOS
JetStream
JavaScript Benchmark
(bigger = better)
Galaxy S6
Moto G (3 rd
Ed.)
48
14
71%
then there were the cores
(power saving)
37
23%
iPhone 6
iPhone 5S
iPhone 5C
63
21
17%
67%
52
We are developing for people like us,
with devices like ours
income families …
only access
Opportunity for all ?
Victoria Rideout
& Vikki S. Katz
Winter 2016
knowing your
performance
WebPageTest
results
Fast Phone / Slow Phone
FastPhone
/ SlowPhone
http://bit.ly/29QGQ97
http://larahogan.me/devicelab/
back to m.
?
javascript/
Maybe we could tone down the JavaScript
Progressive Enhancement FTW
(that means it works without JavaScript)
Stay in touch!
webperf.ninja
Thank you