Understanding JavaScript Notes 1

Hey All!

So P1xT has these awesome guides on how to learn programming. I started with the first version of the JS job-ready guide, but recently switched over to the python guide. Luckily, the first bits are pretty much the same, plus extra projects. One challenge, though, is there are just a lot of books on the list. I found myself reading YDNJS series and getting through the first few books was a challenge. The first two were generally easy to ready, but when I got to “this” it was super confusing. I powered through reading it and made my way to “types and grammar” which is where I stopped. I started doing CS50 and some other courses and came to the realization I was just reading them to read them but not really for understanding. (Probably not the goal here). So I thought about going back and re-reading, but right now I just couldn’t commit myself to opening those books again so I’m taking a little detour. I stumbled across this Udemy course called “JavaScript: Understanding the weird parts.” The title had me intrigued.

The intro video convinced me this was the course I was looking for. It talked about how lots of courses and tutorials focus on mimicking code rather than understanding code and how we would learn how frameworks like jQuery work rather than just using them. He mentions that frameworks aren’t bad, but when people are introduced to JS via frameworks then they don’t really understand what’s going on. So when we have to do something on our own or peak into a library, we’re lost.

That’s definitely true for me. I went through netninja’s mongo and nodejs tutorial awhile back, and although it gave me what I needed to move forward with a project, I don’t feel like I understood anything.

As I go through this course, I’m going to share some things that I learn just as an effort to slow down, and really solidify my understanding. I don’t want to just watch it through on 3x speed and then forget about the concepts. So here are my notes from the first session.


Syntax parsers – Basically a program that checks the grammar of your code to make sure it could function and determines what it does.

Lexical environment – Where your code is written matters in some languages. So the lexical environment is where your code is written. Ex: a variable inside a function.

Execution context – Is a wrapper that helps manage the code that’s running. So if you have a function running, it’s being managed by the execution context and can include things not written in your code.

Name/value pairs – Is a name (of like a var) that matches to a value. The value can be other name/value pairs as well.

Object – An object is simply a collection of name/value pairs.

Other things I learned

That global (the execution wrapper) auto creates the global object and this for you even if you have a blank js file. Global objects then can be thought of as objects not included in any function.

I got to get ready to teach, so I’ll probably stop here for now. But only a few videos in, and I already feel like I learned something. And this time around, I feel pretty motivated to check my knowledge rather than just rush through to the next thing. See you next time!