P31-P82 page
1, equal unequal and congruent not equal
Equality is unequal: first converted and then compared. For only one object, call the ValueOf method to get the base type value and then convert it by the base type, and if all two are objects, compare whether they are the same object (reference or pointer value comparison), NULL is equal to undefined, and at least one is Nan equals false, Not equal to true;
Congruent not congruent: only comparison. Returns true only if the two operands are equal without conversion, and, in particular, null and undefined are not identical because the type of the connection is different
2. A function that does not specify a return value type returns a special value-undefined
3. Add properties only to reference types dynamically
1 New Object (); 2 obj.name = "Lisimi"; /* adding the Name property dynamically */
4, copy variables and pass parameters are value replication, value passing, for the basic data type, copy or pass is a copy of the value of the new variable, for reference data type, is also a value pass, but this value is special, is a reference value (or pointer), the reference point to the object is not involved in replication, That means the last two reference variables point to the same object
5. Each execution environment has a variable object associated with it, and all variables and functions defined in the environment are stored in the object. There are many kinds of execution environment, such as global environment, function environment, with environment, and so on, the variable objects of these environments form the scope chain together. The smaller the scope, the more the corresponding variable object is on the chain, the larger the scope, the more the variable object is on the chain, and the variable object of the global execution environment is always the last object in the scope chain.
6, there is no block-level scope, do not declare direct use is considered as a global variable (it is best not to write this).
7. The current JavaScript garbage collection mechanism uses the method of Mark clear
JavaScript Advanced Programming 3rd Edition-study notes-2