js变量提升

Variables declared with var in the global scope and variables declared with var in the scope of the function and functions declared with the function command, the program will automatically ra ...

位运算bit

按位否 Bitwise Not (~) 按位取反 ~N 相当于 -(N + 1),~55 => -(55 + 1) => -56 应用: ~(-1) = 0 function boolIndex(index){ return Boolean(~index) } ...

js相关

hasOwnProperty方法: 所有继承了 Object 的对象都会继承到 hasOwnProperty 方法。这个方法可以用来检测一个对象是否含有特定的自身属性;和 in 运算符不同,该方法会忽略掉那些从原型链上继承到的属性。 * Object.assign 与 ... 比较 * > The spread operator and Object. ...