TypeScript is now one of the top 5 programming languages, but what is it exactly? And why has everyone adopted it in recent years? This week, Paul and Rich sit down with Orta Therox, a former engineer on TypeScript at Microsoft. He breaks down what makes up a type system, how to migrate to Typescript, and why it could be considered “CTO Optimized.”
Paul Ford Humans have a strong tendency to build a full-application platform out of literally any technology. [Everyone laughs.] Like if you’re like, the RFID tags in your sneakers, they’ll be like: yeah but you can run Linux on that and now we’re off to the races.
Orta Therox There’s an app store for it, eventually.
[Intro music begins, ramps up, plays 14 seconds.]
PF Hey Rich.
Rich Ziade Hey Paul.
PF Postlight’s been around for a little while, wouldn’t you say?
RZ I mean in the world of technology we are dinosaurs almost.
PF No, no that’s not good marketing content. Regardless, I want to do an impression of the engineering function at Postlight for the first four years.
RZ Ok go.
RZ So how was your weekend?
PF Typescript, Typescript, Typescript, Typescript, Typescript.
RZ So how was your weekend?
PF So do you know what Typescript is? Don’t pretend.
RZ I do yes, but I think we should give it two minutes of one-on-one. If only we had someone on the podcast who could help us define clearly for the masses what Typescript even is. You know anyone, Paul?
PF Through the miracle of technology, we have here on the podcast—he is muted right now, I’m going to tell him that—Orta Therox. Orta welcome to the Postlight Podcast.
OT Hey, thanks everybody. Honored to be here.
PF Orta you work on Typescript. Before you tell us about your job, what is Typescript? A lot of our audience won’t know.
PF What does that mean: if you had the delete button?
PF Make the monkey dance on the banner ad. Yeah, yeah, yeah.
OT Make something follow your cursor as you drag it around the page. The HTML stuff.
PF And now it’s 80% of the world economy, so—
OT I think it’s all about the editor experience and being able to feel that you can reliably know the changes—changes only in the things that you would expect there to be.
PF What would break before that didn’t break when Typescript showed up?
RZ I see. So it’s sort of making life easier for the developer.
OT Yeah. That’s one of the goals—make life easier for the developer.
OT Honestly, it’s a great question and to some extent it depends in the same way that you would say for any technical migration, right? [Everyone laughs.]
PF It’s very comforting whenever—I don’t know if people know this, but whenever an engineer says it depends I’m like ok, we’re going to be alright, everything will be ok. It depends. [Everyone laughs.]
PF What would that tooling be like for example?
OT A good example would be using a very popular editor like Visual Studio Code, another Microsoft product that is built in Typescript. And there is a person on the Typescript team that interacts very regularly with that team to make sure it’s a very tight experience.
PF Interesting. I don’t think people processed that. So that’s one of the really big well-know IDEs out in the world, it’s open source, I didn’t know that. It’s fully written in Typescript?
OT Yeah it’s a canonical Typescript codebase. It was like the first one.
PF So start there.
OT Either because somebody made it and then has left the company or it’s just really complicated stuff. Those are usually the best place to write Typescript in my opinion, and to sort of add additional tooling around it so that people feel comfortable making changes in these complicated areas of the code.
PF I think what people who don’t program might not realize is that this sounds really simple but this is where all the problems creep in. This is like if you find out that somebody has replaced all your nails with screws and you’re like, oh but I have to build the house. It’s hard to nail screws into the wall. That’s what types are to programming.
PF It was famously a two-week, hey we’ve got to have something to make the monkey dance. Like literally it was we’ve got this thing, we’ve got the web page and the web page is made up of objects itself and how can we make the objects do things that they couldn’t do with just static HTML?
RZ Right and they thought the movie would end there. They thought ok fine you need the name to blink, we can give you something.
PF Yeah, the way it was for documents, so we’ll make the documents a little more lively.
OT Does it? [Everyone laughs.]
RZ Well ok I’ll take that part back. But talk to me about what motivated you to wade into this part of the culture of software development? Because it’s really interesting.
PF Right and I think talk a little bit about the work you’ve done over the years. It would be great for people to hear.
OT I find quite a lot of parallels with woodworking. When I watch woodworking videos I see people make these really complicated jigs to eventually just do one tiny little piece of woodworking.
PF Yeah. [Laughs.]
PF Give people a sense of how popular, right? We don’t need an exact percentage, but it’s more than 1 out of 100 engineers is writing this. It’s big now, right?
OT Yeah, Github releases these sort of rankings where they say how many new files are being made in a new programming language and Typescript is up there in the top 5 and that’s of every programming language.
RZ I want to step out of the development world for a second and talk about the people who interact with the developers—the rest of society. I’ve led teams through a lot of different projects, some larger scale, some smaller. Agency, product, all sorts. And I’ve got to be frank. When they put the case together to change programming languages or to adopt one that just came out two weeks ago, I freak out.
PF You’re actually pretty flexible, though. I mean we’ve got Elixir in production, all sorts of stuff, at Postlight. But I agree with you, you do over time go ugh ok yeah this is the one? This will solve it? Because it’s been 25 years.
RZ Also I’m not CTO of American Express, where there’s going to be immense resistance to change because of the cost of change and the risks associated with it. How should that audience take in? I’ve got to say for me it’s been a learning experience because I want developers to be motivated and excited because better work comes out, better output, higher velocity. They just connect.
RZ True. It wasn’t a full like rip the wiring out and do something new.
PF Cause I’m just thinking of making the case it’s like: yeah ok I guess so. And then everybody’s like more productivity and 40% of people already use it! And you’re just like ugh fine.
RZ Talk about that dynamic a little bit, Orta—the dialogue that often occurs.
OT So I’ve already framed it as incremental revolution.
PF That’s your memoir!
RZ That is wild.
PF Dude, there you go. Dot org is the name of the website. Incremental Revolution. That is such a VC book title.
RZ Oh man that’s a strong move! You’ve got us! [Laughs.]
OT [Laughs.] It’s true though, right? You don’t want to throw away everything and Typescript’s approach of this really long possible migration is absolutely not seen in many of the programming languages at all and I think it accounts for a large amount of its popularity and also what makes it very approachable—to describe to non-technical folks the advantages of using this separate language.
PF You want to know what makes this work? The fantasy of engineering, especially object-oriented development, was that you’d map out the whole world, you’d get it all structured just right and then you’d sit down with that map and say: let’s make the code. Let’s get it all buttoned up, push to production. And obviously it’s an evolving system, good for us. But the reality is you end up with this hairball of inherited open-source code, legacy stuff, things in different languages, APIs with a lot of mismatch. And you’re just kind of in the fog all the time, which we don’t like to talk about that much. Most of your engineering time is kind of in the fog. I just had somebody—I was dealing with a bug on code I wrote like a year ago this morning, because I’m still on the hook for certain things. And it was just like oh yeah I have no idea what’s happening here. No clue, I don’t remember it, I don’t remember writing it, I don’t remember this function. And then you multiply that by hundreds of thousands of functions. So I think that that’s the real world of building stuff, which again makes for terrible conference talk. Nobody wants to go to the incremental fog disaster, no one knows what the hell is happening talk. But if you do something like this where it’s just like ah we didn’t really know where we were headed but it turned out that it’s a lot more organized than it used to be—if you make it easier to organize things, boy does that make people happier.
OT It’s like putting labels next to wires and things like that. It just gives you the ability to not have to follow the wire all the way to the source to try to figure out whether it’s connected or where it’s connected to.
PF Types sort of give you little boxes for things. That’s true, you can point to them. So ok here’s Typescript, it’s a big open-source project inside of Microsoft. Obviously not their priority, it’s not the number 1 thing that Microsoft does. How does that fit into the overall Microsoft Gestalt? You still have Windows. Are they going to take care of this thing going forward?
PF It’s just fascinating to think about Microsoft or really any organization—going that’s an interesting idea, don’t kill it. Most organizations can not afford interesting.
RZ I think there was more foresight than that. I think this speaks to Microsoft’s second wind. Microsoft’s second wind is very much powered by a long game of not being too orthodox about their own ecosystems. This to me is the same rationale as, you know God bless Internet Explorer but it’s time to just move on to Chromium because there’s no value differential there so let’s get on with it, embrace the communities that can power us and off we go and boy it has worked beautifully for them.
PF It feels like the pivot was rather than we need to be everywhere, acknowledging well we’re everywhere and now we just need to grow layers of Microsoft everywhere we are. Put down more and more Microsoft soil that we can then grow more Microsoft inside of it. Does that mean that the entire world is covered with Microsoft like a fungus? Maybe. But it’s effective.
RZ I mean I think they looked at the whole world and said you know what, we could sit here and just stay enamored with our own ecosystem which is Windows essentially and C Sharp and the like.
PF They got spanked on the phone right? There were those moments, too.
RZ That was an experiment, wasn’t it? Weren’t they going to buy Nokia at one point?
OT They did buy Nokia.
RZ They did? They bought it?
RZ Is that why Nokia’s not around anymore? [Laughs.]
PF Yeah that’s why you can’t get any custom ringtones anymore. [Rich laughs.]
OT I think that’s completely right, personally. I think Microsoft got spanked on the phones and phones are the most profitable consumer device. And then had to figure out ok how do we get people into Microsoft ecosystems? Everybody’s building Apple products in Apple languages, Google products are all done in Java. I’m not going to say Windows is a shrinking market but it is definitely a mature existing market where there are a lot of existing systems and a lot of new systems are—usually Webby—replacing them.
RZ Their cloud moves have been—they caught Google flat-footed. Google Cloud is a tiny percentage of what Azure is now. Again, driven by I think a different worldview which is less about self-love and more about ok here’s the new world, let’s go.
PF Well you get more of the world if you don’t try to control it. If you’re just kind of everywhere. Some of us, that’s what open source did—open source is just sort of like well, you know, it just kind of exists everywhere it goes and it shows up in every country and every project and everybody got used to it. Is there anything else you want to hit on? Any sort of advice people should have in the world?
RZ What advice would you give to the young engineer who has the comp-sci degree and the tools seem to change every 65 days? What’s a good place to start? What’s the advice you’d give that graduate?
PF Build something.
OT Build something.
PF Ok don’t start cause—why? You just told me about this cool exciting new thing. Why should I learn the old busted thing first Orta? [Rich laughs.]
PF When’s it all going to compile to Web Assembly? Just run?
PF There we go. I always like to ask about Web Assembly. I’ve been asking about it for six years.
RZ 2015 Paul messages me: this is the future.
OT Well I actually can’t. The thing I’m working on—
PF Ahhh top secret developer!
OT [Laughs.] I know! It’s a stealth startup!
PF That’s good, those are the best.
OT Yeah, genuinely I can’t really talk about much of it. It’s trying to apply web tech in an interesting space for games.
PF That’s cool, so that’s something to watch. When it’s time for you to tell the world what you’re working on, how would people know? How can people get in touch with you?
OT Follow me on Twitter. I am just my first name @Orta on Twitter and I don’t tweet very often, I try to treat it almost as a change log. But I think it’s a great space for developers to be if you’re not there and also a great way to get information.
PF There you go everybody: Twitter. It’s healthy for you. [Laughs.]
RZ The change log for your life. [Laughs.]
PF Well this is terrific, thank you. Ok this is really good because I think right now several hundred business leaders have said ok you can have Typescript in an email while they were listening to this podcast to their head of engineering.
RZ The world’s a better place.
PF The world is a better place. Ok you can have it, have your types as long as it enterprise. Microsoft approved—I’m ok with it.
OT It’s been worked on for 10 years, they know what they’re doing.
OT That’s it. That’s my deadline, tomorrow. [Everybody laughs.]
[Outro music fades in.]
PF And if people want to learn about Typescript, they want to get their head around it, where do they go?
OT Honestly the best source is typescriptlang.org the official website. We redid all of the documentation in the last two years so it is very up to date and it is very approachable nowadays.
PF Great. Well Rich, once again there are new things happening.
RZ I’m just glad we didn’t talk about Clojure.
PF Oof. I still love Clojure, I think it’s a great language, Clojure script is great but Typescript is a little less away from the mainstream of web technology. A little more organic to how stuff gets built. So Rich who are we? What are we talking about?
RZ We are Postlight. Postlight is a very talented group of designers, engineers, product strategists, product managers. There’s a lot of passion for craft inside of Postlight. That’s why this conversation was sparked by a lot of the dialogue that happens inside the firm. Check us out at postlight.com. Reach out at email@example.com. Orta, thank you so much.
PF Yeah, thank you Orta for coming on and many thanks to Preston Richie, one of our lead engineers, for recommending Orta.
RZ Thank you, Preston!
PF Yeah come back anytime.
OT Yeah it was an honor.
[Outro music ramps up and ends.]