[00:00:00] Introduction
Christopher: I find like a technology that is finally like ready and now we need to make a product out of it. And so this is my personal sweet spot. And so this is like the kind of product I'm looking for is like when all of the R& D has been done and like, there's usually like one crazy person like has an idea and everything.
And then I'm going to take like all of the ideas and like actually turn them into like a product people are going to use.
Andrew: Hello, welcome to the DevTools FM podcast. This is a podcast about developer tools and the people who make them. I'm Andrew. And this is my cohost, Justin.
Justin: Uh, we're really excited, extremely excited to have, uh, Christopher Shadoo on with us today. So, uh, Christopher goes by, uh, vjeux, vjeux, how to say
that
Christopher: vjeux.
Justin: vjeux. All right. Uh, so that's V J E U X. Uh, you've probably seen him around if you're a listener of this podcast. Uh, so Christopher works at Meta, been there for a long time.
Worked on a lot of projects that we know and love, uh, react native prettier to name two of, of many, um, Christopher, honestly, such a great pleasure to have you on, have been a big fan of your work for a long time. Uh, you know, Andrew and I started this. Podcast because we really love tools and we've both used your tools a lot.
So this is a pretty humbling and, and appreciate you coming on. Uh, but before we dive into the questions, would you like to tell our audience a little bit more about yourself?
Christopher: Yeah. Thank you so much. And yeah, this is one of the thing is, uh, so I was in France, uh, like I grew up in France and I had no idea that I would like actually do all of this cool stuff, but I always like try to hike around and everything. And so this is also like a super humbling experience for me to be like in a podcast with you.
Like I've watched, like, uh, or like listen to a bunch of your episodes. So yeah, I'm really excited to be there. And my goal with this is to get like people excited about like tech excited about like building stuff excited about open source. And I think this is like one of my successes, like sure, like working on things, but in practice, like this is not, it was never been like just me.
It's like, like my super strengths is like get people excited and like create communities around all of those projects. So I'm hoping this can help with this.
[00:02:24] Meta's Open Source Culture and Projects
Andrew: Yeah. Before we drill into like specific projects, uh, you've worked on just an amazing amount of technology, uh, over the course of your career at Meta. Uh, could you fill our audience in about some of those projects? And then maybe after that, go into how you feel about Meta's open source culture. And How that still holds today.
Christopher: That makes sense. Yeah. So, uh, the, the ones I like most directly influenced. So I helped open source, uh, react. I, uh, co created react native and, uh, prettier. And, uh, also recently I worked on Excalidraw, like a white boarding school. And as part of like specific projects, so within react native, I, uh, like. Came up with the idea of like CSS in JS, which was very controversial and like spawned like a lot of projects around the theme I also implemented the yoga which is a layout engine That's now being used in a lot of like native apps and also like 3GS kind of world So those are like a few of the projects I've, uh, like being involved in that, like myself, like directly, but, uh, going to your, like, uh, points around meta, one of the things that I've been, uh, like very involved is like, how do we make meta like, uh, really good at doing open source.
And so like the origin story, like for me personally is like, I always have been like curious about like, Hey, what is the latest tech And especially for front end. And I thought when I joined Meta, like right out of school, that I had a really good idea of like what the like standard and the world looked like, but in practice, like I joined, uh, like Facebook at the time and I was like super crushed because I felt like I joined a spaceship that has like all of those cool technologies and everything that nobody knew around in the world and everything, but like, Like we were not sharing it.
And so in practice, one of the things that, uh, like Mark Zuckerberg has always been, uh, like a proponent of open source. And so he started, uh, in his, uh, DOM, like using a PHP, Apache, MySQL, like, uh, Memcache. And, uh, he's always been, uh, like really grateful for open source and like pushing for open source. And, like.
Uh, all of the things I mentioned, I felt was spaceship was actually in the hack language, which is like our own variation of PHP. And so when I looked at it, uh, in practice we tried to open source, but like the, um, uh, like PHP, like was not the like, uh, most exciting thing. And like, was like, if you are a PHP developer, like you were like a loser or those kind of things that like, this was like the mindset at the time.
And the, like the team tried, but like never really succeeded. And the, the one thing that was very interesting is, uh, we, uh, worked on react and in practice react, uh, like one of the main thing people think about is JSX. And so it actually came from, uh, our PHP hack stack, which is called XHP. And so we were able to like, add like, uh, like, uh, Quotes, like, uh, angle quotes, uh, into PHP.
And now we also did it for JavaScript. And now when React was released. Like a lot of people, saw react as, uh, like this JSX thing and everything. But in practice, the way I thought about it was like a vehicle to like showcase and share all of the cool stuff that I've seen, like the, the rocket, like the spaceship, uh, from that we've done in the hack space.
And so one of this is, uh, JSX in order to be able to, uh, actually do something like JSX, you need to be able to, uh, change a syntax of the language. And so this is, uh, we, uh, open source, uh, just transform. And in practice Babel came at the same time. And like, we basically like promoted Babel and in order to be able to do this Then the second part is in order to be able to like transform the, um, the language, you need to have a build step. And in practice, I don't know if you remember the time, but like Angular, like one of the main strengths of Angular is like, you don't need a build step. Like you write thing in the HTML and then like.
In real time is going to take your, like, uh, customized DOM and it's going to like translate it and like template that it is and everything. And so like with JSX, you needed to have, uh, like a transform step and build step. And so we also like push for, um, uh, with a web pack. And then one of the thing, uh, the time is like, okay, now, like this is a very serious application.
You also need like a linter. And so this is where like, uh, we pushed for ESLint and, uh, like, uh, ESLint also like started getting in adoption with this. The, then there's also like the, uh, typing around this where like, Oh, like we push flow, but like TypeScript came around the same time and like, okay, now like we also like push the TypeScript.
And so this is one of the things that I'm like super excited about is that not only like, did we open source react but we were able to through this channel and this community to like open source or like ourselves and like push the adoption of a lot of standard, like. Now we actually can do like real programming, uh, on the web, uh, with all of the tools and everything.
And I, like, I think like react ecosystem, like really like, um, like pushed all of this forward. So this is, uh, like the, what I like for the react ecosystem. Like the thing I've been like most proud of is this now going back to open source, like this is for the front end. One thing you may not be aware is like Meta is also pushing open source on the.
Also different, uh, aspects of the tech. So one, which is very interesting is, uh, for the hardware sides. So, uh, if you think about like hardware and data center, like the, I think the thing that came to me for, uh, to my mind is that Google, and so Google like really pioneered like the hardware data center design, but the way they actually like, uh, did it was like, this is our trade secrets.
Like, we don't want anyone to know what we're doing and like. They like, were like, uh, very, very secretive about this. And, uh, Facebook did like, uh, the complete opposites was like, yep. They're like, we are like, we want similar kind of things. But one thing to realize is that, uh, in, in practice, like a lot of the hardware costs is actually like the manufacturing and the cost of manufacturing scales with the, how many people are actually buying.
And even though like Facebook is big, we're not in the larger scheme of thing, like a really big buyer. And so now if we're able to open source, like all of the design that we have in our data center and like a lot of people are using them and contributing to them now, like there's a lot more people that are going to buy.
Uh, hardware. And so we can reduce, uh, the costs, uh, of the price. So this is a very interesting, like, not only like open source, like help with like our software stack, but also like, uh, like the actual, like bottom line costs of the company around like the infrastructure. And you may be aware of like right now, like AI is like the next, like the big thing that's happening and, uh, like Facebook has been in the AI space for a long time and we open sourced, uh, Lama2, uh, and, uh, we're working on Lama3 and Max Zuckerberg this morning just posted, like, we are going to open source Lama3 and everything.
So like, and we have PyTorch, which is open source and like one of the leading, uh, way of. like developing AI. So this is also like a commitment to open source. And so to like, to step back around, like, what is like, why does Facebook slash Meta does this? And one of the thing is like, first, like, as I mentioned, but the thing is, if it's open source, then, uh, a lot of, uh, like when we hire people.
If they're already aware and everything, they're going to like come in and like ramp up like way, way, way faster and be more productive. And the second part is one of the thing that's, uh, is very tricky, like in a enterprise setting is like building like really good documentation, onboarding plan, and like the whole ecosystem.
And one of the thing is like, once you, like, if you want to open source something and like be successful at it, like you need to do this work. And so open source is like a really good forcing function to do this. And this is like a stock, uh, in my experience, like within the company, the project that we open source, like the quality and the user experience and everything is like way, way, way higher.
Then the thing that we haven't, so it's like a side effect, but it's very interesting. Uh, like aspects and overall, like the, as mentioned, like, what is the like company in it in practice, like anything infrastructure related, like the policies, like, yep, you should open source as much as you can want. And like, like you're going to be encouraged.
Now, anything that's product related, like we're not open sourcing anything. And so this is like our trade secret, like how are like things that, uh, are actually like, uh, like giving us an edge and everything. So this is like a very interesting, if you understand this context, uh, like working here is like super cool.
If you, uh, like work in infrastructure and you want to do open source, like go for it. If you work on product, like don't expect, uh, to be able to do it. So I hope it. Gave you a good idea of like, what's the philosophy?
Andrew: Oh yeah. Uh, it's definitely a respectable philosophy. Uh, I open source by default for like libraries is such a good way to work. And as you said, it really forces you to be so much better. And I like of all the stuff you said, like, uh, Meta's commitment to open sourcing AI is like almost the most commendable to me because it's like, I see Google put out papers and say, Oh yeah, we have the best image generation around.
It's like. Well, I'm never going to be able to use that. Uh, but with Facebook, like you, you are giving people the tools to build the future.
Justin: Yeah, I think that is such an interesting play. And I also think that like, you, you, you talked about a few things that like Facebook is like making strategic decisions to like leverage market forces to do things. Right. So it's like, it's interesting how, you know, building and promoting react and, and, and putting a lot of engineering effort behind that was definitely, I'm sure it paid off, paid Facebook because it's like react being the most famous.
Sort of, or like the largest market share, you know, framework that there is currently that, you know, you're not going to have trouble hiring someone to come in to build product. Right. That's like no shortage of that. Um, and, and, you know, it does a lot for, for image and doing all this stuff, but, and, uh, being that I work at oxide, I know a little bit about the hardware side of like what, uh, meta open sources and like how, you know, that has helped, uh, in like the sort of hyperscaler space.
Um, Even though that's still kind of a niche space and it's hard for folks to compete there. Um, but it, it just, all of these, these plays are kind of interesting because there's like, you know, sometimes people do open source for like, uh, this is like an ideological thing. We're just going to do it because we believe like open source is good.
Um. And then sometimes it's like, Oh, well, open source will give, uh, our customers like more confidence in our products. So they can view like certain aspects of it or whatever. But I think like Facebook is kind of unique in that, like, uh, open source is like a very much business strategy beyond just like, yeah, here you have this stuff, but it's just like, you know, for recruiting for, you know, changing the marketplace.
And, and I think, I think with llama. I may I guess like the first version of Llama really wasn't open source. It's just like, and like, at some point, was it Llama one or Llama two that like kind of got leaked? And then we were like, actually, maybe this isn't a bad thing. And then the explicit decision with Llama theory, I think it's just like, there's some interesting market.
Like dynamics there. And I, I'm sure that there was some interesting conversations that happened behind the scenes for why we should do this, but yeah, that's all, that's all super cool.
[00:14:32] Ad
Andrew: Once again, we'd like to think Ray cast, without our sponsors, this podcast wouldn't be possible. Ray cast is an app for Mac that's like spotlight, but better in every way possible. Spotlight can just launch apps, ray cast can contain entire workflows. Besides being able to do all the things that spotlight and Alfred can do. It has a host of other super cool features that the devs have built in.
And even some that they haven't. Ray gas has an extension store. That's just bursting with cool things that you can use it for. I personally have. Over a dozen extensions installed on my machine.
But one of the cool things about the Raycast team is how active they are on social media. You can have a problem with your computer that you don't know how to solve or takes a bunch of different complicated tools. They'll see that and deliver you an extension. There's two cases that I can think of. One is on Twitter. When you might want to use an act character before some texts, as a things like say you're referring to a CSS at layer or an app media query. If you do that, that'll tack the account.
So one way to get around that is by using the zero with space character at the start of it. It's kind of hard to type a zero with space. So the break has team made an extension to insert it right at your text cursor.
Rick has doesn't stop with just that. With Ray CAS pro you can access all of their team features. And Ray cast AI. Ray cast AI looks like they're going to add some really cool features.
Soon. I saw Pedro Duarte from Ray CAS playing around with anthropic a new LLM, right in Ray CAS.
If you want to learn more about Ray CAS, head over to Ray cast.com or if you want a more in-depth look at what Ray cast is. We did an episode with the CEO back at episode 38.
Wanna help. Support the podcast even more and not hear these ads become a member on Patrion, apple or YouTube, you can subscribe to the podcast and not listen to any of these ads. But if you don't want to do that, you can also buy our merch head over to shop.dev tools.fm, to see what we got.
Would you like to sponsor dev tools, FM head over to dev tools.fm/sponsor to apply. And with that, let's get back to the episode.
[00:16:41] The Birth and Evolution of Prettier
Christopher: so transitioning into some of the like concrete projects you've worked on, uh, one that's arguably saved millions of developer hours is Prettier. Uh, for everybody who doesn't know, Prettier is a code formatting tool that makes. Formatting your code.
Andrew: Not like there is no questions anymore. It has the format and it goes for it. Uh, what a recent thing happened that I found pretty interesting was you posted a challenge, 10, 000 to, uh, rewrite prettier basically in rust and make it super fast. So could you, uh, fill us in about the details about how that started and how it ended up?
Christopher: Yeah, so yeah for prettier like this goes all the way back to when I was in college and, uh, like in my college, uh, this was like called a pizza and this is like a computer science, uh, like focus college. And one of the things that they're doing is, uh, they have you like write like coding assignments. And so, so far, like.
This is, uh, like pretty usual, but the twist is you have to follow a style guide and, uh, assignments are graded on like a grade of, on the, up to 20 and like you lose points if like, uh, the tests are not passing, but you also lose points if you don't meet the style guides. So you can think of it as ESLint.
And, uh, like if you don't actually meet it, you would like lose actually two points per like a violation. And so like, if you have 10 violations in like a few hundred lines of code, then you've got zero. And so this is very harsh and you didn't have, uh, ESLint, like the actual program to verify, you just had the PDF, like those are the rules.
And so one of the thing that, uh, like it made you learn is that the value of like actually like, uh, enforcing the guidelines and everything. And when I was at the school, I was like, okay, this is stupid. Like, why are they doing this? And like, there's no points. But then I joined, uh, like Facebook, uh, like a proper company and everything.
And, uh, like my first, uh, like review. Uh, it was, uh, someone, uh, and she like basically told me like, yep, no, this is not how it should look like. And this kind of thing, and like very long and everything. And I was like, oh my God, like this is continuing, like what's happening? Like why is she doing this to me?
And then, uh, like, okay, but I did it. And then, uh, like six months later, like somebody joined the team and I realized, Oh, I'm actually the one asking for this. And then one thing I realized is that in practice, having a consistent, uh, like style is actually very, very useful because when it's not now, like your brain has to, uh, like spend more time trying to understand like how it's somebody and everything.
But this is only like. Like, this is one part of the equation. The other part of the equation is all of the time and the situation that people are spending into this. Like for me as an engineer joining Facebook, I like move halfway across the world, like married my girlfriend to be able to like actually join.
And the first experience I had like with a Facebook engineer was, uh, like this, like to it felt really bad. And also like, I've seen like. So many hours and days and weeks wasted arguing about like the style guide and everything. And you can also see it like as I interview people, like a lot of like the conflicts that are happening with people are with code reviews and those kinds of things.
So it actually has a big impact. And so at this point, I was very convinced that like, this was a problem that we should solve, like as a, like company and like, uh, as an ecosystem. But the issue is like, I didn't have like a solution for this. And like, I tried to cheat, uh, like at school and try to actually write a program that would like follow the rules.
And I realized, Oh, actually it's very complicated. And nobody like first year or two years, like graders, like were able to actually do it. And this is where I saw like, uh, GoLang came up with GoFMT and I was like. Mind blown. I'm like, they solved it. Like they were able to like write a program that actually does it for you and would solve all of this.
Now the challenge with GoLang and GoFMT is like, they started the language with the formatter. And so in practice, like you didn't have a choice, like you had to use it. But JavaScript I was using at the time and like hack, like already had like decades of like people writing code and like in, uh, like various ways and everything.
And so like, there wasn't this strong incentive to do it, but I was like, yep, this is. Like this is the play. And so what ended up happening is like, I started like passively looking at like anyone that was actually trying to write a formatter, like in JavaScript. And over the years I've seen like many of them going and all of them like actually failing.
And so at some point I was like trying to figure out why, why, like. Passively like on the side, I was on my project and everything. And so I started like reaching out to those people and trying to ask, Hey, what happened? Like, why didn't it work and everything. And the thing that's like, uh, a lot of people were saying that like, oh yeah, like, uh, setting up a style guide and like convincing people is hard, but what I.
The, I think like I knew that, but the thing I didn't know that in practice, the shape of the project is very unique in a way that it's, uh, basically, uh, it's really easy, like to get the 80 percent working correctly. And so in an afternoon, you can actually like get, uh, like a full, like full JavaScript, like a printer.
But the issue is like the last 20 percent are like really, really, really hard and really long. And like, takes a lot of work. And this is like my understanding of like why all of those projects failed is that the people working on them were not committed enough. To actually go through the, the lengths of like fixing every single thing.
And this is one thing is like, if you don't now, what can happen is like, Oh, you format your code and like your code doesn't have the same semantic. And so now like, if you're doing this, if you're running a save and like it changes, I introduce is a bug. You're never, ever, ever going to use it again. And so I spent a lot of time like, uh, like shaping this, but.
I wasn't like, I didn't know how to write a pretty printer. And so like, I put it on the back of my mind, like this is one product that needs to be sold. And then, uh, during a winter, uh, I knew two people like for a side project started working on the Javascript pretty printer. So there was Peter van der Werf who was in Facebook and there was, uh, James Long, uh, like outside of Facebook.
And, uh, they like both told me, Hey, I'm working on this. And I was like, yep, this is the moment. Like finally, like there's like two people working on this. And so what I ended up doing is basically acting as a cheerleader where I like hyped both of them around, like, yep, you can do it and everything. And I started, uh, creating a test suites.
Uh, like a jest, uh, test suites of like, uh, programs. And I like use the same, and then I started comparing like both of the projects. And so every day I would like run, uh, like the current set of the project and say, Hey, this is how it looks like. And, uh, like this is the optimal, this is optimal. And also like doing a leaderboard of like all of the, like node types, like all of the like syntax types.
And, oh, like you are like at a 50 percent and James is at like 60%, like go, go, go. And, uh, like we hacked on this during the winter break, uh, like the three of us like this. And, uh, I was super excited because at the end of the winter break, I felt like, uh, the two project actually, well, like. Realistically possible to actually ship and actually work.
The challenge is like, both of them were like, yep, this was a good like a vacation project, but have a real work to get back to. And I was like, what's like, I cannot let it like stop. And so I ended up. Basically telling my manager, I, I'm, I'm doing this. And so I spent the next six months actually like, uh, like pushing it.
And like every day, like, uh, like fixing like 10, uh, like edge cases and like starting to convince people internally, like, Hey, you should be using it and everything. And so I ended up like doing this. So this is like the beginning of, uh, the prettier projects. Now, the question you asked was more like, uh, what happened last month. And so what, and so like overall, like prettier, like has been like very successful now, like everybody's using it. And one thing I was like, super sad is, uh, on the JavaScript, uh, yearly survey, they actually stopped asking this because, and the reason they tell me is like, yeah, it's. Prettier now is like gets everybody's using it.
So there's no point in asking. And I was like, okay, this is good. But like, I still want to know anyway, but, um, one of the like biggest thing that, uh, the product hasn't succeeded is, uh, and people have been complaining over and over is like the performance and, uh, the. In practice, like for like, uh, saving on file and everything, like the performance is reasonable.
Uh, and because of that, a lot of people were like, yep, this is fast enough. Like we don't need to really push for it and they are right. But I still like every single like a month, there's somebody that tells me like, yep, we should rewrite it in Rust. We should make it more performance and everything. And at some point I got fed up.
I'm like. Yep. Like we should rewrite it in Rust. And, uh, one of the things that I mentioned is like the long tail is the most important. And so in practice, what, uh, like was the challenges, there's a lot of Rust project that are like doing JavaScript formatting, but they don't implement all of the long tail.
And because of that, I cannot. Like actually recommend them and we can't get the perfect. And so I was like fed up and i'm like, yep, i'm going to put a bounty of ten thousand dollars around like Let's actually get it. Uh, like implemented and like whoever can like pass the test is going to actually like get the money.
Now, one of the, one of the reason I did it is like, I actually don't want a Rust implementation of Prettier. I had like a second agenda behind this is I really wanted Prettier itself to be faster. And I couldn't find a way to convince people. And so my idea for this was, uh, we're going to, I'm going to like basically not snipe people showing them, Hey, Rust is faster, Rust is faster.
And, uh, like, uh, somebody is going to like say, Nope, I can like actually make it faster in JavaScript. And so this is what happened. And so Fabio. Uh, like reach out to me and say, Hey, I have a lot of ideas on how to make, uh, like a prettier, faster. And in practice, uh, yeah, I was like, yep, like go for it. And he spent, uh, like a month or two, like walking, uh, on this and he made like prettier, like dramatically faster, uh, through this.
And so this is like, uh, like the, my two, like, Agendas are working. One is like, we have a, like an equivalent in Prettier and Rust for all of that one. And like Prettier itself is getting faster. Now you're going to ask me like, what about the money? Like, did I actually spend the money myself? And in practice, the answer is no.
So Prettier, like, uh, there's, uh, on GitHub, you can, uh, attach an open collective. Uh where people can donate and so prettier has been like successful enough like over the course of the entire project I think we have like had 150 000 that have been donated And so the question has always been like, how do we actually spend the money?
And this is like, one thing that's very tricky is that in practice, 150, 000 like is a lot of money. But if you compare to like the engineers, uh, like in engineers or like my, uh, like income and everything, like. It's almost nothing. And so this is like a very interesting thing with like open source, uh, funding is like, how do you balance the two?
And so one, one thing I did was to, uh, like, uh, like my first instinct was, okay, I'm going to give like a one time payments for all of the people that contributed. And one of the thing is like, uh, and so I said, like, I think it was like 5, 000, I'm going to give 5, 000 to anybody that has significant contribution to prettier, like over the years.
And practice, like only one person, like actually like collected the money. And the reason for this is like, or like a lot of the people that are actually like working on prettier, like our successful software engineer, like have a, like high income and like 5, 000 while a lot of money is like, not. That's like a meaningful amounts.
And there's also like the guilt around, like, why do I deserve this and not like somebody else. And the last one is also like, uh, the taxes implications while I actually receiving money outside of your main walk is actually like a lot of paperwork. And like now, like during tax season, you need to do something special.
It's a lot of people opted not to do it, but I was like, okay, so now like this is not working. I can't give money that way. The other way I found is like, I asked like the core contributors, uh, Hey, are you interested in actually like, uh, receiving, uh, like, uh, like what, like you've already been working on it for like a year or two, like, do you want to get like a monthly salary with this?
And so right now we've had for the past two years, like two people that are getting like 1. 5, 000 every month. Uh, to like, keep like, uh, maintaining pretty on the sides. And, uh, like this has been like a really well working process and, uh, in practice, we have more money than this. And, uh, so I was like, okay, we're going to allocate like 10, 000 for like this price and, uh, yeah.
So this is, uh, like the story around this. So if you, like the audience have been using Prettier and you find it
valuable, and, uh, like, please, like, do not hesitate to donate, uh, on the
GitHub, like we are using the money. And if your company is, uh,
doing donations also, like would be a good
target.
Justin: It's cool. I'm glad that y'all have had some some success with getting some people in. And I definitely can relate to the, both the like challenges of figuring out how you spend the money and the sort of like guilt that can come around with like, Oh, I got paid and nobody else has, and like, yeah, it's sort of interesting.
There's something that I think about sometimes it's like. You know, someone who spends a lot of time on something, if you offer them like a small amount of money normally to what they're used to making, it's like, is that insulting to them? Like, you know, this is like some weird, weird stuff. I want to talk about, uh,
[00:31:28] The Shift from JavaScript to Rust in Tooling
Justin: something else that you mentioned though.
So, um, I think your, your strategy of using the Rust implementation of Prettier as bait to, to get somebody to improve the JavaScript version is really funny. Um, but there is without a doubt, a big groundswell of movement towards Rust and other native languages for implementing tooling. Um, so we had the, uh, one of the, the maintainers of biome on recently biome being, uh, the Rome JS, uh, open source fork, um, you know, building JavaScript tooling in rust.
Um, so how do you feel about this shift from JS to other
Christopher: Yeah. So I'm actually like very supportive. Like one of the things for like JavaScript is really good and fast, but it's actually missing some primitives to be really good for tooling. So the one thing is like startup costs. And so in practice, uh, JavaScript is like fully interpreted. And so like, if you want to like start like a binary with JavaScript, you have to pass all of the, like a JavaScript code and everything, and then you need to like start executing it.
And the problem with this is like, this is like costly. And especially with Node. js modules, like there's a, like proliferation of them. And, uh, like. One of the other thing is, uh, around, uh, like file IO access, uh, if you spin into like many different files, like, like there's a fixed cost for reading a file from the file system.
And so like all of this adds up. And so we had the same issue, uh, with, uh, react native. And so we actually, uh, like implemented our own JavaScript engine called Hermes. And, uh, one of the like big thing we did with Hermes is like startup time is the most important metric and not the actual like, uh, running time, which most of the like VM JavaScript VM I've optimized for is like, Oh, I'm running the same thing in a loop, like a hundred thousand times.
And, uh, one of the ways that we've been able to do it is. Uh, to change the representation of the code from a source string, uh, to like a very optimized thing that you can just like loads and like get super fast startup. Now the issue is like, uh, when you're looking at a tool, uh, this is happening, uh, like on, uh, like machines and everything.
And right now the dominant way for doing, for using this is nodes. And node doesn't have the same, uh, like properties. So the second part is, uh, the, like one of the ways, like most of those projects, like in Rust are getting a lot of the performance is through parallelism. And right now the issue is like JavaScript doesn't have good parallelization, uh, like primitives.
So one way that, uh, most of those tools are doing is they basically like create a new process. And then, uh, you do like, uh, like you talk between the processes, but that means that like all of those processes, like get the full JavaScript VM and the overheads. And in practice, like the JavaScript VM have not been optimized to like run like a hundred times.
If you have a hundred calls, they'd be optimized to like, Oh, there's one running. And like, this is the main one. And, uh, so like, I think there's a going to be like, uh, I want to have like better primitives for doing this kind of things. Uh, like for this. And so I think with those two like big things, uh, are preventing, uh, like the tooling in JavaScript, uh, from being like the same order of magnitudes, uh, as Rust with the same amount of efforts.
Right now, like in JavaScript, you can actually get to there like pretty close, but the issues like the effort needed, uh, to do it is like way higher. And this is not idiomatic ways of, uh, working. So for example, like one of the most costly operation, like when you're looking at the low level, low level like this is memory allocation.
And in JavaScript, like everybody allocates arrays and I do map and everything, like we didn't need it. And if you do that, like, you're going to have like a performance overhead. Like that is the way you write code. And in Rust, like the people like are, uh, very conscious about like memory allocation and like the primary language that gives you like a lot of tools to not do it.
And so in practice, like the way you write code that way, uh, is also like, uh, naturally like faster. So I think this is like, the thing is, uh, I think there's a place in time where like, uh, JavaScript can actually like be as fast as Rust, but we need to have like a lot more investment from like the primitives of the language and the ecosystem to be able to do it.
So. I don't think it's doing everything. I think we can get there. And, uh, the Hermes team is doing a lot of work with, uh, static compilation of, uh, JavaScript and like, uh, like prioritization and, uh, like fast startup time. So like there's hope there, but. The world today is not there now, uh, going to like, okay, now we, like, we're going to a different programming language and I actually think rust is a pretty good one.
Like the, by default, like the performance is like, uh, like much better and also the. the language like looks and feel like, uh, like a language like JavaScript. And, uh, like it's a modern language with like, there's map, there's filter, there's like all of those like utilities that like you would see in JavaScript.
So the translation between the two languages is like very similar. And, uh, the other like container like C plus plus, but there's a lot of like manual memory management, which is like a lot harder. And like, uh, with like food guns and everything, there's also OCaml, uh, which like we, uh, learn flow and hack and a lot of systems.
But the issue is like, this is still like a very esoteric language, uh, with like both the syntax and, uh, the like way it works. So I think Rust is a good target. And I'm really glad that like we have like, or going to like. The Rust ecosystem is going to grow and, uh, like we're going to have like really, really good and fast tools for the web.
So overall, like my conclusion is like, I wish it would be in JS and like, this would actually like from an ecosystem perspective, like in JS be like a lot better, but there are fundamental things like prevents
it from being
the case. So I think, uh, Rust is the like, uh, like, uh, like the really good alternative for
this.
Justin: Yeah, it's kind of, it is kind of interesting to see how it like grows and changes. I mean, so with the, the sort of introduction of other runtimes, you also have like, different sort of, uh, foreign function interfaces where you can write native code that interacts with like, you know, node or Dino or bun or whatever.
Um, and I, I think it's been nice to see that that support has gotten better and the, the development story around that has gotten better. umm So, yeah, it'll definitely it'll definitely be interesting to see where this goes, because, you know, if we think back several years ago, five years ago, most people wanted to write things, JavaScript tooling and JavaScript, they're like, you know, I want to be able to come to this and contribute and understand.
And I want to broaden how many people can contribute. And, um, now, you know, we're moving, getting more bullish on performance, which is good, uh, but also, you know, has its own trade off. So it
[00:39:03] The Evolution of React and its Tools
Justin: will be interesting to see. umm Maybe shifting gears a little bit, uh, let's talk about another project that you worked on.
So, uh, you'd worked on, uh, create react app, uh, which had a lot to do with, you know, the proliferation of react in general, I think. Um, and definitely sort of like entered, uh, like ushered in a new age of spa. Uh, what do you. Uh, what do you think of the current tools, uh, uh, for like creating ranked apps, like, what do you think
Christopher: Yeah. So actually like when, uh, we open source react, like what I really wanted was to have, uh, the Ruby on rails equivalent around react. And, uh, this is like something that, uh, I feel like in practice, like. Meta and Facebook, uh, like is really good at like, uh, like open sourcing and like building react and everything, but we were not the right like place and company to actually build something like rails because like.
We use like React in a very different way internally and like tied to all our systems. And this part like was not as easily like factorable out, uh, like to deliver like to people. and so I've always, uh, wanted, uh, to have like this rails, but, uh, in practice, like, uh, I think, uh, we started the Create React app like two or three years after like React.
And, uh, like this rails, like, like was not in sight and I was like, okay, so if like, nobody's going to like build a raise, we should at least, uh, get the, like, initial getting started experience, like, uh, working a lot better. And so this is where, like, I, uh, worked with, uh, Dan, uh, and like in the, like first few weeks and like, we like hacked on this and like, Dan, like ran with the project that I run off.
Uh, and so the idea was like, okay, how do you like get started with reacts? Like in a, like non shitty way. And like, you don't need to like wire up like 20 different tools and everything. And so I think that, uh, in practice, the, the life cycle, uh, that happened is, uh, like create React app was like very, very useful, uh, to get started.
And one of the things that I found in practice is, uh, like the. The, like the creating, like a react application, I actually think, uh, Next.js and, uh, the Vercel environments, like is the one that's like most, uh, looking like the ideal, like I had with, uh, like, uh, Ruby on race. And so I know there's a lot of controversy with versatile and next and like how they like got people and everything.
But to me, like, I haven't been like in the react team for a while and everything, but like. To me, this seems like what I wanted originally. So you're able to like go and click, uh, yeah, create a new project. And like, Oh, you've got like all of the skeletons, all of the templates and everything. And now you're like, there's a button for deploy and like, Oh, you can actually, uh, deploy and also, and then you've got like a website working.
Initially five minutes and they already set up like all of the things and, uh, it also work with like database access and like, how do you actually like, uh, manage your CMS and those kinds of things. Like they have like a lot of those, uh, like feature, like more like an app that you need. And so I think this is the.
Like the evolution I'm seeing, and, uh, I think we still need like a tool like Create React App, like it's bundled with React so I can just get started. But, uh, like, I don't, like, I don't expect this to be the main way people are like building, uh, like React Apps, uh, like for the long time, for long-term
Andrew: So that would make Yerimo our DHH. Nice.
Christopher: I have a lot of, uh, thoughts about this comparison, but
Andrew: I kid, I kid, um, yeah, well, create react app started a lot of my apps and it's cool to see today that there's like, there is Vercel, but there's also remix. Remix is a great alternative to that. And then if you want to like, not have as many of the frills, like just, uh, Vite
does the job pretty well too. So it's, it's great to see that there's a lot of options today.
A lot of them taking inspiration from your initial work.
[00:43:19] The Impact of CSS in JS on the Industry
Andrew: Uh, moving on to another subject. You said you are the creator of CSS and JS. Uh, CSS and JS, uh, has been a controversial topic in my opinion. And we've gone through multiple cycles now. We've seen, uh, frameworks come and go. Throughout the ages. And I think we're definitely like in a, like it's set in now the libraries that are there have found the patterns.
Uh, so now that this dust has settled, uh, how do you think the industry is and like, which tool would you
Christopher: yeah. So maybe I can go back to the history of like how this happened. So in practice, it went all the way back to, uh, when I was working on react native. And so, as I mentioned, I re implemented, uh, like, uh, the layout part of CSS. And the thing is, uh, like we, like. When we were working on React Native, like in order to like build an app, like you need to be able to like draw like things on the screen and you need to be able to like define like for every single element that you have, what is the like top, left, width and height of these elements?
And the way, like, uh, it was done in, uh, like, uh, Objective C and iOS at the time was like literally every single element you would put on screen, you would have to like, give it like it's left with top and height for everything. And it was like a lot of code, a lot of boilerplates, but this was, uh, like how it was done.
And the rationale for this is like in practice with a small screen and like there was only one size, like you need to have this kind of control. But it was like very, very painful. And then when they added like different sizes, like the iPad and everything, like it wasn't feasible to like actually, uh, like do it manually and you need it, uh, to have like some kind of, uh, like layout engine.
And so for React Native, like our, like we, uh, like neither like a layout engine. And so I started looking at like what all of the possible ways. Uh, like well done. And one of the thing I've always wanted was React Native is, uh, I want to be able to write code that works both on iOS, Android, and web. And when I looked at this, uh, the thing is in practice on web is the most restrictive targets because you cannot rebuild like a different layout system for it.
And so this like really helped my decision to like, okay, we're going to like use. Uh, the web layout algorithm now in practice for the web layout algorithm, there was a lot of issues. So for example, like, uh, when you two elements are next to each other, like there's margin collapsing and, uh, there's floats and, uh, like it's impossible to center deep and this kind of things.
And so like, I, I was trying to figure out like, what is the good parts of like CSS? Like we have the good part of JavaScript and, uh, in practice there was, uh, like, uh, a spec that was implemented by most browsers called Flexbox, which at the time was like nobody really used and like really know what to do with it.
But then I started looking at it and I'm like, Oh, This actually solves like most of the problem of CSS. And so what I end up doing is to like start implementing like a CSS, like the layout parts. And so basically, uh, uh, given like, uh, an element and the margin padding, like flex, uh, wrap and everything, like what are the top left, width and heights.
And so I ended up doing this and in my minds, like I was going to also implement like a CSS parser and also implement like the selectors and the rules and everything. But I was like, okay, uh, like already implementing the layout algorithm is like a big task. I'm going to start with this and I'm going to like in JavaScript, uh, like set the values that directly and, uh, using like inline styles.
And, uh, like we started the React Nif project and like, we kept going with this and we kept going and at some points, like nobody was really asking for like, uh, the whole selectors and everything. There was something that people wanted was like on hover and this kind of thing, but nobody really wanted to be able to say like, Hey, I have, uh, a div and like three layers down.
I need, uh, like, uh, to change the property of something like if you're in full react, you can actually pass a prop and, uh, do this propagation like this. And so I was like, okay, so I, I started convincing myself that we didn't need all of the selectors. And, uh, now I was like, okay, so like, and so we didn't implement, uh, like this for React Native.
And, uh, at some point we are going, like, we were about to like open source React Native. And one of the, like, biggest issue that we've had when we open source React is a lot of people got caught on the fact that like we mixed JavaScript and HTML, like with JS tech, like this was a big controversy and like it tainted, like the, uh, the react project for like decades still to this day.
And, uh, I. I was like, I knew that, like, if we are going to open source react native and we were not going to like implement CSS selectors and everything and using inline styles everywhere, like there would be like the same controversy and like a drama and everything happening for this project. And so what I did was to like.
Go to like a small, like, uh, find a, like a small conference that was running, uh, like one month or like two months before, like we open sourced, uh, React Native and signed up and say, Hey, I'm going to like do a talk on this. And, uh, my talk ended up being accepted. And, uh, I was like, okay, so I'm going to make the case that like, uh, putting CSS in your JS.
It is actually not a stupid idea and, uh, can actually like benefit your applications and these kind of things. And so I did the talk and, uh, so it was at, uh, uh, okay. I'll find out the name of the conference, but, uh, yeah, I did it. And like. As I expected, like it exploded, like a lot of people, like, uh, were like upset and this kind of things.
The thing I didn't expect is like, there would be like a huge wave of people actually trying it out. So I was like surprisingly, uh, happy about this. And then, uh, we open source react native and like, basically nobody gave a shit that like we didn't implement CSS selector because like all of the drama was around like CSS and JS.
And so like from a perspective of like what I. I intentionally did this for like this works, but I didn't actually expect like this whole, uh, like sprawl of, uh, like libraries going around this. And now this is like, one thing is, uh, I have like one big regret is that so far I've never seen anybody, uh, actually benchmark for real the performance of a CSS.
And so a lot of people are saying that like, Oh, using inline style is actually slower. But to me, like this statement doesn't make sense because if you think about it, uh, what does inline style do is like you take a style and you set it on the element itself. And so like you're doing basically zero operation in between.
And so this should be like the fastest thing you can do. but now people are saying that, like, actually, like putting the specific style on a different programming language and, uh, like starting to pass this one and then to compute all of the rules and find the element that are like matching the selector and everything, and then like putting it there is actually faster.
And so this is the thing that doesn't compute in my mind. Why would it be faster? And to this day, I've never had anybody like actually show me a benchmark, like, why is it faster? And, uh, like that is actually faster. And. And, uh, also an explanation of like, why would it actually be faster? And so I'm still waiting and like, this is my call to everybody in the space.
Like, please show me a benchmark and, uh, give me a rationale around why it would be faster. And if you're able to do it, then yep, like you can do it. But yeah, I don't know. And so in practice, uh, for the question, the original question you ask around, like, which library to use and everything. Honestly, to me, it doesn't matter because, uh, what matters is like in practice that you put like your style next to, uh, like in the same file as, uh, your like, uh, components and whether you use like, um, like, uh, actually nice style in JavaScript or whether you use like some CSS, uh, decorators kind of things like, like, this is the, like.
It doesn't change the shape of the problem. It doesn't change the shape of your code. And, uh, like there's like minor things. So I think you can use like all of them. Uh, I don't think there's a major difference.
Andrew: Yeah, I love the nerd sniping, uh, some more of that, uh, the JSX thing is interesting because I recently saw a tweet, uh, that was like, uh, you like JSX, that's the part of React you like, and I was like, what, just smacked because it's like. a decade of people going JSX is the worst thing in the world, and now like newer developers are like, oh, that's the good part of React, it's just so mind blowing.
Christopher:
Justin: I remember that being a thing too, is like a lot of people like, hating on JSX. And I think the, the, sort of like. Brilliance of a lot of the work you and the other folks at Meta have done is, is realizing that like things should be shipped together. Uh, you know, it's just like we had, yeah, it was like, we're trying to build one piece of UI and we're like crossing like three boundaries of languages to like try to stitch it together and how kind of insane that is sometimes.
And like this idea is like, no, you're building this one little piece of UI. Put everything you need right there. And it's yeah. I mean, it just like, of course it works. That's yeah, it's been, it's been pretty good.
You know, as we've talked about, you've, you've worked on some really prolific work, uh, and, and, and all of these have made some pretty significant impacts on the industry in their own ways. Um. So, you know, like prettier, obviously we've, we've talked a lot about like how that really just went from making, you know, formatting something we all talked about to like, nobody wants to think about it anymore.
Uh, you know, I think like Excalidraw, which we haven't talked too much about, but like when that project came out, that was like, you know, really nice because a lot of the other diagramming tools that were out there, so it's like behind paywalls or like not really high quality or like they're trying to get to a different fidelity or whatever.
So it's just like having that, uh, react native and yoga. You know, incredibly, incredibly valuable things in the ecosystem. Uh, so what, what's next for you? What do you, what are you thinking about now?
[00:54:04] Exploring the History and Future of AI in Software Development
Justin: Like, what's that, that problem that's like bouncing around in your head?
Christopher: Yeah. So it's two problems. Like the one that's like most actionable is like, uh, the whole thing about gen AI. And, uh, so one of the things that, uh, like last year in January, I was like, chat GPT is like, this is the best thing that ever happens. And like, but the issue is like within the context of a company, you cannot use it.
Because like, uh, it doesn't, it's not trained on all of your data and everything. And so I spent the past year, uh, within, uh, Meta to actually like, uh, work on, uh, a product like ChargeJP that is actually fine tuned on all our internal, uh, like code base, uh, feedback group, wiki, uh, like tasks and everything.
And, uh, I'm really glad like it actually worked really well. So now a lot, like a lot of people, like within the company, even though it's not even one year old, are using it like every week. And like, this is part of their like workflow. So I think this is less, uh, about meta, but like other people, uh, I think there's like a big, big, uh, like, uh, going to be like a big.
Uh, thing where you can actually like have within every single company in the world, something like chatGPT that actually works for like, uh, like actually can ask questions and like has the context, the internal context. So I think like on a big trend, uh, within the world I've pushed within the company, uh, we're going to see this and this is like less like useful to like talk about here because like, it's not open source and like, it's probably never going to be open source.
But, uh, yeah. And this is why I'm like really excited. Like Facebook is, uh, like meta, sorry, is working on Lama and open source and everything. So we give you all of the tools so you can do this kind of things. So the other part of them, like very, um, like, uh, like thinking a lot about is.
[00:56:02] The Future of Video Editing and the Role of AI
Christopher: All of the video editing.
And so in practice, uh, like you're doing podcasts and you're probably like doing these kind of things. And I feel like a lot of the tooling around this is, uh, like, hasn't evolved, uh, with the age of like creators and everything. And so all of the tools are still like the tools we've used like before. So one example is, uh, like when you're editing video, like a lot of the video is about the text.
It's about the voice that you have. But if right now you put like your, like, uh, video and voice on, uh, your video editor, you're going to see like a sound wave, uh, for the text. And right now, like all of the AI for like, uh, speech to text is actually like working really well. And so, uh, like there's a big potential for like AI.
And so same for like, uh, removing the backgrounds.
right now you need to install like a special extension and everything while like zoom and like, uh, hangout and everything like removing the background is like now the default and everything, but not in this. So I think this is like, uh, something like there's a needs, uh, like for this and the challenge, uh, and the second part is, uh, actually the web.
Now the browser is capable of doing video editing is capable of doing all of this. And, uh, so that's a new tech called web codec, where you're actually able to use the hardware of your like computer to do video encoding and decoding, uh, within the browser. And so I've like spent a time like testing, like, Hey, is it fast?
And it's actually as fast as final cut pro, like re encoding a video. And so I think there's a lot of, uh, like, Potential there, uh, to do it on the web. And right now, like one thing I'm seeing a gap is, uh, there's no goods, like open source tooling, like for video editing on, uh, like the browser. And so if you look on the like server and everything, like FFmpeg is being used and like, this is like everybody in the industry is using FFmpeg.
And so it's relatively like easy to bootstrap like a UI based on this. But if you look at the web, like we don't have like the equivalent of FFmpeg and we don't have the equivalent of like this kind of like low level structure for like manipulating video. And so in practice, what happened is like, we have like a company like Descripts or Clipchamp that are doing like really good, like work, but the issue is like, they have to rebuild the entire video editor from scratch.
And then they can do like the thing that it And so in practice, like a clip champ decided to like, go like, okay, I'm going to do a full like video editor. And, uh, descript was like, okay, we don't have the time and resources to do like a proper video editor. So we're going to focus on like, uh, the text to speech, uh, speech to text, like part, and you can like cut things.
But I feel like there's a gap where like, we have like an open source baseline video editor and, uh, now like, Oh, if you like have ideas around this, like, Oh, now you can like start contributing and like building features. And, uh, I think it would marry very well with, uh, Excalibur. Well, like a lot of the video editing is actually like, um, like the animation is like, Oh, you have like things on the screen and you want to be able to resize them, move them and everything.
So this kind of capability. And then, uh, a lot of the animation and transition are actually like 3d. Like space and we have like React 3. js and a lot of shader work and everything that people have been building over the time. And so I think, uh, like combining like all of them into like one experience that's open source has a lot of potential now, like I've been procrastinating and, uh, like with a bunch of other things.
So I, I'm not like actually like. Working on it. But if you're like asking her, like, what's on my mind and I'm like, what is the next big thing? Like this part is like one thing that I feel like right now is the right time and space for like something getting there.
Andrew: Yeah, over the past few episodes, we've had this theme of a new web technology becoming a thing and then that like creating companies. So like, uh, if we look to Figma, we can, uh, see like, uh, Wasm, WebGL, that sort stuff. We look to StackBlitz, we can see web containers and all of that. And we're really like right at the forefront of web codecs being that I, I work at Descript as, you know, and we use them and it's still very much like bleeding edge.
Like Safari doesn't quite work yet, but I think we're, we're definitely on this precipice of web video companies just springing up overnight.
[01:00:37] Having Impact
Andrew: one of the things that's striking, you know, about this conversation and about your work it's like you, you obviously have a knack for, for picking high impact areas of open source. Um, so. What do you look for when looking for like a good project or area to work on?
Christopher: Yeah. Yeah.
this is something like I'm like the, I'm very high risk kind of person, high rewards. Uh, and so this is the kind of thing I'm drawn to. And, uh, like there's a lot of people shapes, like how they work and usually like, uh, and one thing I've realized about the years is like, Uh, for many projects, you can think of them as like an S shape.
So there's the initial like long project where like, there's a lot of like research that needs to be done. And like, there's not a lot of impact, but like, you need to like research and like what Andrew was talking about, like, uh, the web codec and like all of those technologies, like there's a lot of time, like where the technology has to back and be ready.
And then like, this is usually when I come in. Is I find like a technology that is finally like ready and now we need to make a product out of it. And so this is my personal sweet spot. And so this is like the kind of product I'm looking for is like when all of the R& D has been done and like, there's usually like one crazy person like has an idea and everything.
And then I'm going to take like all of the ideas and like actually turn them into like a product people are going to use. And so I'm like starting at the beginning and like, okay, how do we get like the initial customers? How do you convince people like this is not crazy and it's going to work and everything?
And like, let's start it from the exponential part of the curve. And then usually this is where I like, I get disinterested. I'm like, yep, I've like set up the thing and like, it's going and like, and so like, I'm keeping that as like, yep, I want it to be that way. But I like. Like, uh, leave the space. And then, uh, at some point it's going to like start, uh, tapering.
And this is like the last curve of this. And this is where like, uh, this is where like, okay, this is like a mainstream technology. And now like you need to do like iterative, uh, improvement, like incremental improvement that like have a lot of like value, uh, as a whole, because like the lot, like the user base is so large.
But, uh, like they are like smaller changes to, uh, the project. And so this part, like, this is like, I don't enjoy, uh, like being in this space. And so now the, um, the thing that makes me like very, like a very weird, like, uh, person is that. I don't actually know what I'm going to work on next usually, and I have a lot of like nagging problems that I know, like, and I'm like looking for and everything.
And, uh, I'm basically like wait and I'm always talk like talking and what is the next, like, uh, technology and everything. So I'm talking to people and like what people are excited. And then usually it's like, Oh, finally, like something clicks. And so for example, like for like the, my work on chatgpd is like, Oh, chatgpd finally came in and Oh, now I can actually make a product out of it.
And for Pretio is like, Oh, I had this long nagging thing. And Oh, finally, like Peter and James, uh, like started, uh, like working on this. So, okay. Now I'm going to latch onto it. And so it's more like Zeus, like, I wouldn't say opportunistic, but like. I'm, uh, like waiting and seeing and like, feel like, okay, what are all of the things that are like annoying, uh, me on a day to day and everything.
And at some points I'm also looking for like, what are the trends and like, what are the things. And, uh, like there's something that's going to like, now, when, uh, like I have a hunch that something is going to work out, I spent a lot of like my mental energy and time trying to like prove myself wrong. Because in practice, like, these are like crazy projects and like, uh, like if it, like My, uh, usual thesis is like, if, uh, it makes sense, somebody would have already done it. And so I'm really trying to figure out like, why didn't people like succeed at it? Or like, why, like, what other things people tried and feel like, why did they fail?
And like the, like, is the reason that they, that they failed still valuable? Uh, like. Uh, like make sense today and, uh, all like, did they actually like, did not execute well and I can change it, but I'm trying to like figure out, okay, what, why didn't it work? And then for my like personal hunch, now I'm trying to figure out like, what, like, why couldn't it work?
And so, for example, for react native, like one of the big thing was performance. And so this is where like, uh, we spent like a lot of time, like, uh, so Jordan Walk in particular spent a lot of time trying to get like a smooth, uh, list view, like a scroll and like, it's tried like so many different things.
And, uh, at the end of like, he spent like six months, like, uh. You know, whole, like actually like trying like so many things. And at the end he came out and say, yep, this is actually working. This can work. Like there's no impossibility. And so now we like, actually like, uh, proceed for one and everything. So like, there's this part of like convincing ourselves that like, this can actually work.
And, uh, once like all of the things that couldn't work, like we have a good idea of like, Why, like, that's not true now it's about the execution. And so for the execution, like a lot of the thing, uh, especially in the early stages is, uh, what I call like setting, setting up the incentives. And so, for example, like one of the thing was prettier, uh, within the context of Facebook is, uh, like I knew that I wanted to have like one way of formatting the entire code base.
And I knew that like, if we have configuration, like people in different part of the companies are going to use a different configuration. And if you let it, then, uh, like now we won't achieve our goal because like now people are going to actually like fight against the goal. And so one of the thing I did for this is I know I want only one.
What is the way you can actually only get one? And so now like. Why would there be more is because like people are going to actually like configure it differently. And so I've been trying to figure out how do we make it so that like if people like configuring it is actually like harder than people are willing to actually invest in this.
And so the strategy I used for this specific one is in practice for Prettier you need you need to have it running on two part of the system. One is on your IDE, and we use Atom at a time. And the other one is on the, your CI, uh, like setup. And that is on like, uh, the servers and like, uh, tied to the code base.
And so what I, what I did was to make sure that we actually, I copy paste the configuration on the integration of Prettier with the IDE and on the configuration of CI. And so like a lot of people looked at me, we are like, Hey, why are we copy pasting? Like those two things, like, uh, this is stupid. Like we should create a config and everything.
And in practice, the reason why I did that, because the, uh, developments, uh, like the, the way, uh, shipping is happening for those two things was decorrelated. So on a nuclei, on the atom, uh, like we shipped every week and, uh, like people had to like manually updates. And then on the code base, it was like based on the commits.
So whichever like commit you are, like it's actually going to work. And so because, uh, this was designed that way, if you, well, the, the one project wanting to, uh, actually use a different, uh, version. Now you had to actually like, you couldn't hack it around because now like CI would be different than the, like the editor.
So if people look saved on the editor, it will work. And so one very, uh, case, uh, like was RoamJS. They actually started with a different config and then as they got more contributor within the company, uh, that's wanted to use like, uh, new clients, like, uh, sorry, Adam, this was the internal name, uh, they would save and they would be frustrated and.
It was more work to actually find a way to do a proper rollout and add the config system and everything than to actually just change the configuration to like whatever it was. And so we ended up like having them move to like the same one. And so this is like a, the incentive structure around like what can fail, like how do you like set it up?
And there was a lot of them that we did on the react native on like all of my projects. So it's like one year, two years, three years, five years down the line. Like the incentives of doing the, uh, of not doing the wrong thing was stronger than the incentive of doing the right thing. And, uh, like people in practice, like have a.
Uh, a tolerance for like how much work they want to, uh, involve. And so you should like, if you don't want them to do something like make this work, like higher than, uh, the previous work, and then you're going to get like a good system that can actually grow without you being involved.
Andrew: Yeah, you, you create a bigger pit of success than you have a pit of failure. And so people follow fall the right way.
Christopher: Yeah. That's one way to talk about it.
[01:10:02] Future of AI Software Dev
Andrew: yeah. So last question here. We usually ask like a future facing question. That's like specific to the field that the person's working in. You've worked. In so many, it's hard to really do that.
So, uh, we'll do it a little different this week. Uh, with the advent of AI tools, a lot of people think that our jobs will go the way of the dinosaur. Uh, I don't quite think that, uh, but what do you think the future of our future of our industry looks like, and what our what our jobs might entail in the future?
Christopher: Yeah. So I think, uh, like I think a lot about this and I think chess is like a really good analogy. So like. When, uh, like Deep Blue beat Kasparov, like a lot of people were saying like, oh, chess is dead. Like now the computers are better and everything. But in practice, this actually did the opposite effect is actually like trigger like a whole new wave of people that's where, and like, uh, of discoveries around chess.
And now it's no longer like, uh, one human versus one human, but like one human, uh, helped with a computer and, uh, to be able to, uh, like, like play against like somebody else. And now what, what you are able to do is this is like starts thinking about theories. Oh, what if I do that? And then you can have the computer say like, Oh no, it's not working because in 20 moves are like, this is going to be in a bad situation because of this.
And so now, Oh, so if I need, I need to prevent this and then I'm going to do something else. And so now like players are like much better because they have like this, like instant tool that is able to give them feedback and like help them like intuition and like do some things and it helps them actually be better.
And so the way I think about it for Uh, like software is like very similar. So in practice, like a lot of what we're doing as a software engineer is actually not engineering software is actually doing repetitive tasks, uh, of like, Oh, like one example is like, uh, you mentioned like, uh, co locating like things.
Like if you, at like 10 years ago, if you wanted to create a product, like a JavaScript, like page or something, the first thing you need to do was to create three files and like a one JavaScript, one CSS, one HTML, and now like, we're only creating one. And so this is like, Oh, now you're doing less work. But there's still a lot of boilerplate.
Oh, you need to like add all of the imports. You need to like, uh, configure like, uh, whatever, like style you're using. Like there's some boilerplate around this. Uh, you need to do like, uh, find like, what is the, the right component in, uh, like the design system that I need to use, uh, to do things. And, uh, you actually need to type a lot for this.
And so I feel like. A lot of this like mundane work of like, yep, I need to like copy paste the example, or I need to like do a lot of typing and everything like is going to be like vastly accelerated, uh, using AI. The other part that was very interesting, uh, like with our AI work, uh, within, uh, like the company is, uh, like the more junior people are, the more they actually use.
AI assisted, uh, tools. And in practice, uh, one of the thing when you're junior is you need, like, usually like need to get your knowledge from a senior person. And like, this is not a very effective way of doing this because a lot of the questions are basic and everything. And so now if you have like a problem that can actually help you with like, Uh, the easy question and kind of things now, like that you're going to like be more productive as a junior engineer and your senior engineer is going to be more productive because they can actually start thinking about like the bigger, like more difficult things.
And I've seen this also in my experience, like whenever I have an algorithm that is like tricky and I don't know out of my head, like how to do it. Whenever I asked like any AI that we have out there, like none of them are able to actually like solve the problem if I'm not able to do it. But. At some point, like if I need something simple, so at some point, uh, I wanted to try out like a game of life in 3d.
And I literally typed, uh, please write me in game of life and like using three GS and everything. And like judge GPT was able to like, just like build the things I wanted. And so this is the kind of thing where like, I don't think our job is going to be replaced, but I think our job is going to be accelerated.
And especially all of the more annoying thing that you have to do are going to be like removed. And now you can have like more time spending around like the actual, like real questions, uh, like our real problems that, uh, like you cannot copy paste from Stack Overflow.
Andrew: Yeah, I agree. Uh, I've uh, many a time compared our jobs to being plumbers, and now it's just like, we're just getting a tool that helps us do the job better in a little bit more of an automated way. Well, that wraps it up for our questions for this episode. Uh, thanks for coming on. This was a super fun conversation that touched upon, uh, many like foundational technologies of modern, like front end. So thanks for coming on and talk about them.
Christopher: Thank you so much. It was like super awesome. And I really hope, as I mentioned at the beginning, that like my talk here is like inspiring all of you to like, think about like, what is the next like big thing or like, what are the things that are frustrating day to day and it's possible to change them.
Like when react, I was like 23, like not even out of college and
everything. Like you don't need to be like senior in the field and
everything to like make changes. Like if you have ideas and like, you're willing to like walk on it and like, uh, like, uh, like get people like together and everything, like you can also do
it.
Justin: Yeah, that's an inspiring message. And I'll definitely echo that. It's, uh, we, we need more people trying more things. Uh, and you know, if you have ideas, build them, uh, such a, such a pleasure to have you on Christopher. Uh, you know, again, as I said in the opening, we're both big fans of your work, uh, and you know, your, your influence has definitely helped shape our industry a lot and, uh, yeah.
Again, that's an honor. So I appreciate you being on.