标签:性能 nbsp eof typeof lse OLE goole 区分 als
typeof null - ‘object
typeof undefined - ‘undefined‘
Boolean(null) - false
Boolean(undefined) - false
Number(undefined) - NaN
Number(null) - 0
123 + null - 123 (null - 0)
123 + undefined - NaN
null == undefined - true
‘undefined‘ in window - true
goole
keys(window).length 372 避免直接与 undefined 作比较(避免性能浪费,应该使用 Boolean 去区分)
标签:性能 nbsp eof typeof lse OLE goole 区分 als
原文地址:https://www.cnblogs.com/justSmile2/p/9844604.html