some of JavaScript’s dirty tricks
¶ by !undefinedA couple of quick ones:
// Date -> Number:
var d = +(new Date());
// 1281743590756
typeof d;
// number
// almost anything -> String
d += “”;
// “1281743590756”
typeof d;
// string
// anything -> Boolean
d = !!d;
// true
typeof d;
// boolean
What are…