I've spent the last ten
months as a developer
evangelist
7
Slide 8
Slide 8 text
This means I've talked to
a lot of developers.
8
Slide 9
Slide 9 text
Given ~ 20 or so talks
9
Slide 10
Slide 10 text
And listened to many,
many more
10
Slide 11
Slide 11 text
Teaching
—ES2015
—React
—Elm (!)
11
Slide 12
Slide 12 text
Thoughts and Opinions
12
Slide 13
Slide 13 text
It's basically me rambling
for a bit
13
Slide 14
Slide 14 text
The State of JavaScript
14
Slide 15
Slide 15 text
Or: a series of things that I've been thinking about.
15
Slide 16
Slide 16 text
Or: how we keep getting it wrong and then getting it
right
16
Slide 17
Slide 17 text
!
17
Slide 18
Slide 18 text
Never been a better time
18
Slide 19
Slide 19 text
JavaScript gets a lot of
stick, some of it deserved
19
Slide 20
Slide 20 text
[1, 2, 3].map(parseInt)
// => [1, NaN, NaN]
!
20
Slide 21
Slide 21 text
But it's still the best
language ever
21
Slide 22
Slide 22 text
Browers are getting more
powerful
22
Slide 23
Slide 23 text
More and more APIs
being added
23
Slide 24
Slide 24 text
The native DOM API isn't
complete crap!
24
Slide 25
Slide 25 text
Low Level APIs
25
Slide 26
Slide 26 text
Service Worker vs App Cache
https://vimeo.com/album/3953264/video/165995029
26
Slide 27
Slide 27 text
App Cache
High Level, does one thing, hard to customise /
control
27
Slide 28
Slide 28 text
Service Worker
—Low level
—Less functionality "out of the box"
—Developers get full control
28
Slide 29
Slide 29 text
NodeJS
29
Slide 30
Slide 30 text
Learning as an industry
30
Slide 31
Slide 31 text
Native learning from
frameworks
31
Slide 32
Slide 32 text
document.querySelectorAll
32
Slide 33
Slide 33 text
=> from CoffeeScript
33
Slide 34
Slide 34 text
Object.observe
34
Slide 35
Slide 35 text
1. Two way data binding is great but needs dirty
checking which is...dirty
2. Let's implement Object.observe natively to deal
with this
3. Oh hey, ReactJS!
35
Slide 36
Slide 36 text
Object.observe
No More
36
Slide 37
Slide 37 text
Cumulative learning from
competing frameworks
37
Slide 38
Slide 38 text
MVC doesn't work for
client side applications,
even though it's great on
the server.
38
Slide 39
Slide 39 text
It was a logical starting
point; we knew no better.
39
Slide 40
Slide 40 text
We tried it and we learned
40
Slide 41
Slide 41 text
Angular 1.X moved heavily to components.
Ember 2 removed controllers.
React only has components.
41
And some are less loved...
class Crockford extends IDontLikeThis {
constructor() {
this.mistake = true;
}
}
54
Slide 55
Slide 55 text
2
New features in ES2016
55
Slide 56
Slide 56 text
Array.prototype.includes
56
Slide 57
Slide 57 text
Was going to be called contains, but MooTools
adds Array.prototype.contains... 2
2 https://esdiscuss.org/topic/having-a-non-enumerable-array-prototype-contains-may-not-be-web-
compatible
57
! Load Instantly (Service Worker)
! Add to Home Screen
! Web push notifications
! Secure
! Fast
! Responsive
https://developers.google.com/web/progressive-
web-apps/
143
Slide 144
Slide 144 text
Offering a great mobile
experience on the web
144
Slide 145
Slide 145 text
Flipkart, India’s largest e-
commerce site, decided to
combine their web presence and
native app into a Progressive Web
Application that has resulted in a
70% increase in conversions. 6
6 https://developers.google.com/web/showcase/2016/flipkart
145
Slide 146
Slide 146 text
Server Side Rendering
146
Slide 147
Slide 147 text
147
Slide 148
Slide 148 text
GoCardless is a universal
ReactJS application 7
7 https://gocardless.com/blog/how-we-built-the-new-gocardless.com/
148
Slide 149
Slide 149 text
Once the initial page is
displayed, a request is
made to fetch the rest of
the site's React app.
149
Slide 150
Slide 150 text
All subsequent navigation
is blindingly fast, not
suffering the latency of
HTTP requests since the
browser already has the
whole app.
150
Slide 151
Slide 151 text
If the user does not have
JS, they still experience
the fully rendered page
and only miss out on the
fast navigation.
151
Slide 152
Slide 152 text
—Ember Fastboot
—Angular 2 Universal
—And others
(This isn't for every app!)
152
Slide 153
Slide 153 text
https://www.youtube.com/watch?v=Bb0Uk8c6ltQ
153
Slide 154
Slide 154 text
Is the web getting more
complicated?
154
Slide 155
Slide 155 text
It depends
155
Slide 156
Slide 156 text
Is it hard work to build a
performant, mobile
friendly, offline first web
application?
156
Slide 157
Slide 157 text
Yes
157
Slide 158
Slide 158 text
But that's exciting!
158
Slide 159
Slide 159 text
No one is making you
build complex,
progressive, offline first
apps in the browser.
159