!!在js中的用法

var obj = ""; //undefined
console.log(!!obj);  //false(强制转换成Boolean类型)

原文地址:https://www.cnblogs.com/lj8023/p/10287852.html