Transcript from the "Introduction" Lesson
[00:00:28] I'm sure some people here and online have watched that course before. And I wanted to explain the context of this one which is expanded, new coverage of content, deeper coverage. But I wanted to explain the context of that compared to the previous one. So first, let me start with the title.
[00:01:01] And I've had people complain like, wait a minute, I thought I was getting like every kind of like hot framework and acronym of the weak or whatever and all you did was talk about closure. I didn't get my money's worth. So, I've had that sort of a complain.
[00:01:15] And then on the other end of the spectrum, when you show up and you teach something that is genuinely more deeper and more rigorous than people are used to and they show up thinking, it's gonna be a lighthearted intro. They get quickly frustrated, because it's over their head or it's going faster than what they expect.
[00:01:30] So there's this interesting balance between what you call it, the expectation that that says and what that will mean to people's perceptions of the value that they got out of it. So after a lot of reflection, I decided that the reason I called it advanced was I wanted people to know this is a lot more rigorous than you're used to going with these particular topics.
[00:01:53] But I always had to give that caveat. This is not what most people called advanced. Because most people say, well, advanced should be all about the tools like the gulps and the web packs of the world and we don't cover any of that stuff in either the previous course or this one.
[00:02:32] That's what the expectation should be. So, I'm setting that expectation with the title of the course. I just wanna let everybody know that. We're not gonna be covering a broad range of topics that will leave your head spinning. What we're gonna do is cover actually a rather narrow set of topics, but we're gonna go much deeper with those topics than most people are used to going with them.
[00:02:53] Hence, the title. If you have read my book series, the You Don't Know JS books, you would know that those books are also very rigorous. So, expect that this course will be somewhat like that. Although if I would had teach the full contents of this books, we would be here for weeks at a time.
[00:03:09] So, if you looking for where do I go next? He says a thing and I wanna understand that deeper. I wanna go deeper with that. The books are the best place to go and you can read the entire book series for free. All 6 books, the 1,100 pages worth on the GitHub repo.
[00:03:24] So I strongly recommend that you track along or for those of you who are watching this after the live experience, go and take breaks and track along with the book and read that. Because that is how you'll go even deeper than the coverage that we'll have here in this class and in these things.
[00:03:40] So if you have watched the previous course, the tactic is the same. We're gonna continue to go deep with these core mechanics. In some ways, we're even narrower than before. Because previously, we covered asynchronous topics and that's now become its own full-fledged two-day course as opposed to just an hour tacked onto the end of the day.
[00:04:02] So, we're narrowing the focus in some respects. But in other respects, expanding the focus on the things that we really ought to know. And I thought while doing that, it would be a good opportunity to actually go back and come up with a fresh set of exercises to practice on that.
[00:04:17] And in the previous course, there were only three or four exercises to go over. There are eight for this course, so there's double the number of exercises. It's actually one application that we go back and work on in each of the eight exercises. So we progressively go back and reexamine it, and work on it, and improve it throughout the course of all the exercises.
[00:05:02] Most people take the prospective that coercion is some ugly necessary evil, if you will to the design of the language or it's poorly designed, even the creator of the language himself claims that he made a bunch of mistakes in the design of it. And so oftentimes, when I stand up and say, actually, I think this is a pretty great part of the language.
[00:05:22] It flies in direct contrast to a lot of the established wisdom on the topic, but I think understanding types and understanding the way the types are converted which is coercion and using that to our advantage rather than being scared of them and staying away from them. Understanding that mechanism, that's the first core pillar of the language.
[00:05:45] And I don't think you can go anywhere else with the language, if you don't really have a solid foundation of that. So we're gonna start with the types and coercion system, really dig into what that's about and get into those details. Now the truth is we have to go through a mired set of details, which can be a little bit convoluted.
[00:05:59] We have to go through mired set of details for you to get the perspective that you need to have on that topic, but it will not be the case that in your day to day thinking or in your day to day development that you have to think about every one of those details.
[00:06:33] Cuz it turns out that closure is actually, probably the most important concept every invented in all of computing science. If not the most, it's in the top two or three. Now, some of you know that Doug Crockford and I don't always agree. We don't always see eye to eye.
[00:06:50] He's a smart guy, has a lot of great stuff to say. And every once and awhile, he says something truly profound. And he pointed out on this topic, he was talking about closure in a conference talk some years ago. And he pointed out that if you look back at the history of computing science, turns out that the most important concepts that were invented took an entire generation of programmers before they took hold.
[00:07:13] And his tongue in cheek theory for that was well, whenever something new is invented, all the existing crowd is resistant to change. Because why do I need to change it? So, we have to wait long enough for them to all die or retire before the new crowd can take over with these new patterns.
[00:07:29] And he goes on to say, we know that closure is truly great. Because it took two full generations to take hold. So, I think closure really is actually the most important of all the foundational concepts. And when you start to understand what that is and you start to recognize that in all places of your code, you'll start to agree with that.
[00:07:48] So, we're gonna spend some time talking about that. But again, that surfaces to us a set of patterns, namely the module pattern for code organization. It surfaces to us a set of patterns that we hopefully can use as instincts in writing better code and the third and final core foundation that we'll cover in this course is that these, and object prototypes system.
[00:08:22] But if you tell me you can articulate exactly the difference between and object, the prototype chain and the closure in lexical scope chain, that's what really gets me impress.