SlideShare uses cookies to improve functionality and performance, and to provide you with relevant advertising. If you continue browsing the site, you agree to the use of cookies on this website. See our User Agreement and Privacy Policy.
SlideShare uses cookies to improve functionality and performance, and to provide you with relevant advertising. If you continue browsing the site, you agree to the use of cookies on this website. See our Privacy Policy and User Agreement for details.
Successfully reported this slideshow.
Activate your 14 day free trial to unlock unlimited reading.
7.
#LDNWebPerf#webrebels
In the strictest sense, anything served to
the client that’s provided by an
organization that’s not the website
provider is considered to be third-party
“
”–Ben Vinegar, Author of “Third-Party Script”
What is a 3rd party script?
8.
#LDNWebPerf#webrebels
Types of 3rd party scripts
Advertising
Tracking and Analytics
Fonts
Social Media
Libraries and Frameworks
9.
#webrebels
What’s the #1 used
3rd Party script?
23.
#webrebels
- John Hjelmstad
Google I/O 2012 (How we Make JavaScript Widgets Scream)
The value you get out of the widget needs to be
greater than the performance hit you are taking
Rule of Thumb
24.
#webrebels
A user who has to endure an 8-second download delay
spends only 1% of their total viewing time looking at the featured
promotional space on a landing page.
In contrast, a user who receives instantaneous page rendering
spends 20% of viewing time within the promotional area
(source: Jakob Nielsen)
“
”
Perception of promotional space
31.
#LDNWebPerf#webrebels
A single point of failure (SPOF) is a part of a
system that, if it fails, will stop the entire system
from working
–Wikipedia
SPOF
32.
#LDNWebPerf#webrebels
The Offender
It will block rendering anything after this line
33.
#webrebels
Yeah…whatever
3rd providers don’t really go down…
77.
#LDNWebPerf#webrebels
Pages using Google CDN
(Top Alexa Websites)
0%
0.25%
0.5%
Jan '11 Jan '13 Jan '13 Jan '14 Jan '15
11%
17%
26%
37%
47%
Percentage
Google Hosted Libraries
PAGES USING GOOGLE
LIBRARIES API
52%
48%
78.
#LDNWebPerf#webrebels
Anywhere?
Don’t just copy and paste
82.
#webrebels
Source: May 2015, Big Query result on jQuery from Google CDNs
Google’s hostest jQuery fragmentation
OTHER
30%
1.4.2
5%1.11.0
6%1.8.2
6%
1.11.1
7%
1.9.1
8%
1.8.3
8%
1.10.2
8%
1.7.1
10%
1.7.2
12%
83.
#webrebels
So, whats the verdict:
Hosted Libraries or not?
96.
#webrebels
Title Text
https://github.com/triblondon/
Contribute on Github!
97.
#webrebels
Next time before
you copy and paste
98.
#LDNWebPerf#webrebels
• Refuse 3rd party content that doesn’t provide async
options or is not minified
• Put the risk in the SLA (uptime etc.)
• Review jsmanners
• Educate other (junior) developers
• Test it via navigation and resource timing where applicable
What to do as a Publisher & Developer
99.
#LDNWebPerf#webrebels
• Ask for server-side options
• Evaluate tag managers
• Investigate hosted libraries (if no own CDN is available)
• Monitor, monitor, ….and monitor
• Evaluate the need of the script with marketing and
sales
What to do as a Publisher & Developer
100.
#LDNWebPerf#webrebels
What to do as a Script Provider
• Provide non-blocking code samples and snippets
• Educate developers, and verify the integration of
your script (proof-check)