PAUL LEWIS: If you were born at any other point in history,
you'd be completely stuffed.
JAKE ARCHIBALD: I'm full of [INAUDIBLE].
PAUL LEWIS: What would you have done
if programming wasn't a thing?
JAKE ARCHIBALD: Die in a ditch.
I would.
I really would.
PAUL LEWIS: It's a really happy tale, isn't it?
JAKE ARCHIBALD: Yeah.
[MUSIC PLAYING]
So I want to talk about Pointer events.
PAUL LEWIS: Right.
So the CSS thing where you say, Pointer events none.
JAKE ARCHIBALD: No, the other one.
Because the other spec that they made before,
we're going to write a new spec.
I know, let's name exactly the same
as an existing CSS properties.
PAUL LEWIS: Yay.
JAKE ARCHIBALD: No.
I'm talking about the events one.
PAUL LEWIS: Oh.
Those, those are brilliant, right?
Detailed spec, unifies touch, mouse pointers, and gives you
all the everything that you ever need
to just bring it all together.
Brilliant.
JAKE ARCHIBALD: It's great.
We're not doing it.
PAUL LEWIS: What?
JAKE ARCHIBALD: We do have good reasons.
It's a really detailed spec.
It says the order of all, how everything should happen.
But there are performance issues.
It's very similar to mouse events.
You know when you move a mouse across the screen
and you get the mouse move events and the target changes
after every element.
PAUL LEWIS: Yup.
JAKE ARCHIBALD: Pointer events works in the same way.
And that means that as you're doing a touch action,
it's going to have to do this hit test throughout the touch.
PAUL LEWIS: Oh.
JAKE ARCHIBALD: Big performance problem.
You could actually-- to be fair to them,
you can set a capture on it.
But then you've still got the enter and leave events
on the element that you've captured.
That's a big performance no-no.
And the unification stuff that you mentioned--
PAUL LEWIS: Yay.
JAKE ARCHIBALD: It's not as good as you think.
PAUL LEWIS: Oh.
JAKE ARCHIBALD: I don't know about you,
but whenever I use touch events, which we already have,
I usually use it because I want something special
to happen with touch.
PAUL LEWIS: Yeah.
JAKE ARCHIBALD: Like a swipe action, or something
that I wouldn't want to do with the mouse.
PAUL LEWIS: Right.
JAKE ARCHIBALD: And that's what I find most of the time,
that there are occasions, maybe like a drag and drop action,
where you'd want touch and mouse doing the same thing.
But mostly, not that.
PAUL LEWIS: OK.
JAKE ARCHIBALD: And there are also
features that it stops as well.
So pointer events, what seems like another plus point
for them, is it's either the user agent, the browser,
dealing with the touch stuff or you.
No in between.
So if it starts scrolling, you're out of the picture.
But we have features that need that.
For instance, you're scrolling.
You scroll to the top.
And then you drag down.
PAUL LEWIS: Pull to refresh?
JAKE ARCHIBALD: Pull to refresh.
So that's you letting the user agent do part of it.
And then you want to take over at that point.
You can't do that with pointer events.
PAUL LEWIS: Oh.
That's horrible.
JAKE ARCHIBALD: Right.
And it's just all of these little things
that have got in the way.
But the main one is, we already have touch events
in all the major browsers except IE.
And pointer events are not good enough
to justify kind of throwing that out,
because we would have to support for ages for all the sites
anyway.
And the good news as well is Internet Explorer,
they recognize that touch is not going away
and they are going to implement it as well.
PAUL LEWIS: Hooray.
[MUSIC PLAYING]
JAKE ARCHIBALD: I wanted to get something else off my chest.
PAUL LEWIS: Oh, no.
Not again.
JAKE ARCHIBALD: I know.
I know.
And I want to talk about getting undressed
because it's not something I'm very good at.
It's not something I'm very graceful at.
But we bonded over something about this.
PAUL LEWIS: Yes, we did.
JAKE ARCHIBALD: And I wanted it to go over it again,
because the final moment of undress, which
is when I've gone through the clumsy uncool underwear down,
and then what happens.
PAUL LEWIS: You absolutely have to do a flick with your foot,
whoop, catch, and then slam dunk into the wash basket.
JAKE ARCHIBALD: And then all of a sudden,
all of the clumsiness--
PAUL LEWIS: Yeah, it's gone because you're
naked and cool at that point.
JAKE ARCHIBALD: Yeah.
You're the coolest naked person in the room.
Right.
But I was at home doing clumsy undress and then the recovery,
whoosh, boom.
And I thought of you.
Paul.
Naked Paul.
How am I expected to live my life?
PAUL LEWIS: Now, we get an API, the web smoothness API.