1.prototype and __proto__
The __proto__ of all objects point to the prototype of their constructors, the prototype of constructor
2. Problem with variable scope
It is often assumed that the value of a variable cannot be found in the current scope to be searched in its parent scope, which is not accurate and should be found in the scope of creating the function.
Var b=100; Var fun1=function() {alert (b)}var obj={ B:ten, fun:fun1}obj.fun () // The result is
3.settimeout method
The SetTimeout method delays the execution of the function when the JS engine is idle.
Var b=0; Settimeout (function(B=1;alert (1)), 0) while (!b) {}
Here will never alert 1, will enter the dead loop, if the second parameter of the settimeout is 0, even if the JS thread is idle, will not be executed immediately, the browser has a minimum time, the impression that IE is 4ms, Firefox and Google do not remember
So much for this time.
JavaScript Note points (2)