- promise are use to handle async operations in JS
- easy to handle callback hell
- also use to handle the errors
- Pending
- Resolve (then method)
- Reject (catch method)
- initial stage of any promise is always pending
- technique to chain mulitple asynchronous operation in a specific order by chaining together using promise
- mechanism by which we can change the document structure
- structure html document elements on the web
- we can use document object and it's method for change the document structure such as toggle the button and etc
- getElementById
- getElementsByClassName
- getElementsByTagName
- querySelector
- querySelectorAll
- addEventListener(event, callbackfunction)
- combination of two or more nested functions
- where the inner function access the variable for the parent function
- in it's lexical environment called closure
- Arithmatic +, -, *, **, /, %, ++, --
- Assingment =, +=, -=, *=, /=, %=
- Bitwise bitwise or | , bitwise and &, bitwise not ~, left shift <<, right shift >>
- Comparision ==, ===, <=, >=, !=, !==
- Logical operator &&, ||, !
- Ternary (condition) : true block code ? false block code;
- typeof - return datatype
- non primitive datatype that stores key value pairs seperated by colon
- key also called Property
// method 2 - using new keyword let obj = new Object(); obj.age = 23; obj['name'] = 'Jane'