📅  最后修改于: 2022-03-11 15:03:07.433000             🧑  作者: Mango
var trueTypeOf = function (obj) {
return Object.prototype.toString.call(obj).slice(8, -1).toLowerCase();
};
// Returns "array"
trueTypeOf([]);
// Returns "date"
trueTypeOf(new Date());