校验数据类型
export const typeOf = function(obj) { return Object.prototype.toString.call(obj).slice(8, -1).toLowerCase() }
示例:
typeOf('树哥') // string typeOf([]) // array typeOf(new Date()) // date typeOf(null) // null typeOf(true) // boolean typeOf(() => { }) // function