Talk
The Weird Web
What does a piano, a soldering iron, an Xbox controller, and your web browser have in common? Most often we use the Web platform to paint boxes on peoples screens, but it is capable of so much more. Join me as we explore some of the weirder Web APIs, like Web Audio, Web MIDI, Web Gamepad, WebUSB, and Web Serial. Lets learn how we can use these features to add capability, accessibility, and delight to your apps.
Bio
Alex makes fancy websites. His favorite project is Thorium, an open-source starship bridge simulator. He enjoys rock climbing, baking, and CSS.
Share
Interview
Hello, everybody, I am Kent C. Dodds and I'm joined by my friend, Alex. How are you doing, Alex? I'm doing well, how are you? I'm super. Alex, you spoke last year at Epic Web Con. I did, yeah, it was great fun. You know, one of my favorite things, one of the best compliments that somebody can give you,
I say this as a speaker, is to ask you to come again. That's like, people can say, oh, you did a great job, but if they want you to come again, now they really mean it. And so I really did feel like you did a great job last year. And then, like, on the flip side, I've just been realizing I have a couple people
who are coming to the conference again as an attendee. We have Dev, who came as an attendee and now is coming as a speaker. And I realized, like, the reverse is also true. Like, the conference wasn't so bad, I guess you want to come again, so that's a good thing. Absolutely, yes. So anyway, Alex, I really appreciate you
wanting to come to Epic Web Con. Thank you, I'm flattered, Kent. Yeah, okay, so for those of you who did not get to meet Alex last year, Alex, can you give us a little intro to yourself and who you are? Yeah, I live here in Salt Lake City, so this is a local conference for me, which is nice.
I make fancy websites, the fancier the better. So the fanciest website that I make is my spaceship game, it's called Thorium Nova, and the idea is you play as the crew on the bridge of a futuristic sparship going out into space and doing missions, exploring, that kind of thing.
So that's all built with web technologies, and it is what gets me into my biggest trouble when I'm trying to do weird stuff with web browsers. Yeah, you know, I've played around with it, it is pretty cool. And one thing that I think is pretty interesting and underappreciated for those,
for folks who are into the sci-fi stuff a little bit is how big space is, and like how far, like we're navigating to these different planets and ships, and it's like, yeah, that's gonna take like, you know, a million years or whatever to get there.
So yeah, it's pretty interesting. How do you deal with that? Bending the rules of physics. Anywhere where I am doing that in the code, I'll say, this is space magic, and that's just what I have to do. It's necessary, but still fun. I'll give a small example.
I can't remember. The speed of the fastest object which humankind has ever made is the Parker Space Probe is currently visiting the sun, it orbits around the sun. And as it gets to the closest part of its orbit, it goes really, really fast.
And it's able to go 692,000 kilometers per hour. Yeah, it's really fast. That's 192 kilometers per second. In order to maintain the narrative structure of a game so that you're not bored traveling between places, you need to be able to travel really, really fast
to get even from the earth to the moon in just a couple of minutes, instead of in hours or days that it took the Apollo astronauts. Yeah. So the cruising speed for one of these ships is 1,500 kilometers per second, which is an order of magnitude faster
than the fastest thing humans have already created. So just a little bit of space magic, just for fun. Yeah, yeah. Well, you know, we've got to do things to make it enjoyable for us regular humans who are impatient. Absolutely, yes, mere mortals. Yeah, very cool. Well, I have been really impressed.
And actually, I selected your talk before you submitted it. So for this fun backstory, Alex presented at the, I think it was the Remix Meetup, not the, yeah. And I was just blown away by the cool things that you can do with the web.
Alex's talk is titled, The Weird Web. And I always am impressed by the cool stuff that the web can do, that it like goes beyond just the little boxes that we typically are doing on the web in our day-to-day jobs. But like pushing it further, like 3D in the browser or working with serial ports or whatever,
Bluetooth and all of that stuff, this stuff that we don't typically do. And so Alex gives this really cool presentation. And I say, hey, how about you do that at Epic Web Conf? And we can like do some really, I don't wanna spoil anything, but we've got some interesting plans. I think that if it works out, it's gonna be pretty exciting for folks who are there.
So anyway, why don't you tell us a little bit about what you're planning on for The Weird Web without giving away too much? Yeah, I mean, people have seen 3JS and WebGL stuff before, it's pretty common these days, which is awesome. Same with the Web Audio API,
which lets you play different audio streams and manipulate audio in real time in the browser, which is great fun. And then there are some other APIs that are kind of buried in the spec. Like these are spec compliant APIs, not just random stuff that's been added,
that let you use things like game pads in your web browser. Yeah, fun fact, your web browser has information about the Xbox game controller and its layout and how it works embedded into its code. Like it knows what an Xbox controller is. Yeah, it's so weird. There are a couple of other APIs, like you mentioned the Serial API.
I saw Wes Boss did something where he plugged his robot vacuum into his computer and then use the Web Serial API to send it commands, which is just bananas. You can control a robot vacuum with your web browser. Who does that? Well, we do, and it's great fun.
So we'll talk about different things that you can do with these weird APIs that are a little bit more uncommon, why you might use them, have some really cool demos, hopefully really, really cool demos, if again, everything pans out, and talk about why the heck I'm doing it with these web APIs in the first place.
I'm very stoked about that. Like you mentioned how you might actually end up using some of these APIs. Can you give just a couple of ideas of like how is this practical? There may be some people watching right now who are like, yeah, I kind of want to like, I want to go to the conference,
but I want it to be like professionally enlightening and stuff. How is some of what you're going to be talking about practical to the engineers who are just web developers? Yeah, it's all about the users, really, and providing a great user experience. I'm doing it for my video game.
And so there's a lot of video game things that these APIs are helpful with, like the gamepad API for being able to use a gamepad to steer your ship around, or for adjusting the pitch of sound effects. So every time a sound effect plays, it isn't the same pitch, which makes it sound a little bit more interesting
and not boring and same thing over and over again. And those things can apply to regular websites too. If you have some kind of sound user feedback, you don't want it to sound exactly the same every time. You might want to do that little bit of pitch adjustment just to make it so that it's interesting
and not boring every time the sound plays. Or you might come up with a clever way to use the gamepad API to provide more accessible options for people to be able to browse and navigate your website, depending on what type of site it is. Mm-hmm. Yeah, I think that can be one area of differentiation,
right, of just being able to say, hey, look, my site has some sound effects or it has some sort of integrations with your device that you are holding in your hand or whatever. I think it's something worth exploring for sure.
So I'm excited about that. Now, Alex, you have been to more than just Epic Web and more than just local conferences. What is it that draws you to the different conferences you attend? I go to conferences because of the people.
Some of my best friends that I've made, including you, Kent, have been made at conferences and meetups where we talk in person and get to know each other in a way that's difficult over the web, especially over social media. And it's really awesome to be able
to run into people again at conferences or meet new people at conferences that you've never met before, make those connections with people. Yeah. Yeah, I think the primary goal of the conference isn't just education, because that's something you can get on the internet
pretty readily if you find the right instructors or whatever, but the real benefit there is making those in-person connections. And then it's useful professionally, but also just personally. I think that's what makes us human
is the connections that we make with other humans. Yeah, and it's nice to be inspired. That's why I'm giving this talk. It is very aspirational. I don't expect everyone who comes to the conference to be like, ooh, I'm gonna put WebUSB into my app. Like, no, but now you know that it's a thing and that it's possible to do that.
And conferences condense that and concentrate it into a small section of time instead of just kind of getting little nuggets here and there. So lots of inspiration, lots of connection. Absolutely, yeah. So when all those people do come to the conference
and you're standing in the hall and they're just having a chat with somebody, eating a tasty cookie or something, and they wanna walk up to you, what's something that they could talk with you about that would get you really excited? I should wear my Ask Me About My Spaceship t-shirt, shouldn't I? Yeah, definitely. Yeah, I can ask about my spaceship game.
I'm really interested in local-first development. That's what I talked about last year at EpicWebConf. So we can chat about that, end-to-end encryption. Um, baking. I'll talk about baking. Yeah, yeah.
I wonder, maybe we should see if we can have you bring some bread over or something for sample plate. I absolutely could. Yeah, I could. I was gonna offer, so great. I'll put it on my calendar. Make bread the night before. Sounds great. Hey, Alex, thank you so much. I really appreciate you giving us some of your time today.
And looking forward to meeting you there. And hopefully a bunch of other people coming to meet you and chat with you about baking and spaceships and all of that good stuff. For sure. Thanks, Kent. Looking forward to it. Thanks, everyone. See ya.