-
Syntax Parser: A Program that reads and determines what it does and if the grammar is valid.
-
Lexical Environment: where something sits physically in the code you write.
-
Execution Contexts: A wrapper to help the code that is running.
-
Variable Environment: where the variables live and how they relate.
-
Scope: Where variables are available in your code.
-
Callbacks: A callback is a function passed as an argument to another function. This technique allows a function to call another function. A callback function can run after another function has finished.
-
Asynchronous: More than one at a time.
-
Asynchronous Callback: Asynchronous programming is a technique that enables your program to start a potentially long-running task and still be able to be responsive to other events while that task runs, rather than having to wait until that task has finished.
ELI5:
Imagine you’re playing with building blocks. You ask your friend to tell you when they’re done building a tower. When they’re finished, they’ll shout “done!” That shout is like the asynchronous callback – your friend lets you know when they’re done with their task, so you can continue playing without waiting for them. -
Event Queue: The event queue is responsible for sending new functions to the stack for processing. It follows the queue data structure to maintain the correct sequence in which all operations should be sent for execution.
-
Types: Types help us understand and manage the different kinds of data we use in our code. Think of them as different categories for things.
-
Dynamic Typing: Dynamic typing is a concept in programming where the data type of a variable is determined at runtime, while the program is running, rather than at the time of writing the code
-
Static Typing : Static typing is a concept in programming where the data type of a variable is determined and explicitly declared at the time of writing the code, and it cannot change during runtime.
-
Primitive Types: A type of data that represents a single value.
-
6 data types in Javascript:
-
Undefined
-
Null
-
Boolean
-
String: sequence of characters
-
Number: Floating point number
-
Symbol
-
-
Operators: Take two parameters and return a single value;
-
Infix notation: Infix notation is the notation commonly used in arithmetical and logical formulae and statements.
-
Operator Precedence: which operator functions get called first?
-
Associativity: what order operator functions get called in left-to-right or right-to-left
-
Coercion: Converting a value from one type to another
-
First Class Functions: Everything you can do with other types, you can do with functions.
-
Function Expression: A Function Expression works just like a function declaration or a function statement, the only difference is that a function name is NOT started in a function expression, that is, anonymous functions are created in function expressions. The function expressions run as soon as they are defined.
-
Function Statement: A Function Declaration( or a Function Statement) defines a function with the specified parameters without requiring a variable assignment. They exist on their own, i.e, they are standalone constructs and cannot be nested within a non-function block. A function is declared using the function keyword.
-
IIFE: IIFE (Immediately Invoked Function Expression) is a JavaScript function that runs as soon as it is defined.
-
Prototype: A JavaScript prototype is a shared set of properties and methods that objects can inherit from, serving as a blueprint for creating and interacting with objects.
ELI5:
Alright, imagine you have a special toy box that has all the rules for making other toy boxes. This special toy box is like the “prototype” in JavaScript.
Every time you want to make a new toy box that works just like the special one, you can use it as a guide. This means the new toy box will have the same features and abilities as the special toy box.
So, the special toy box is the “prototype” that shows other toy boxes how to be, and those other toy boxes are like objects in JavaScript that use the prototype’s rules to work properly.