madrobby / zepto

Zepto.js is a minimalist JavaScript library for modern browsers, with a jQuery-compatible API
http://zeptojs.com
Other
15k stars 3.93k forks source link

$.type() does not support Symbol & Event & Set.... #1327

Open onlychild opened 6 years ago

onlychild commented 6 years ago

$.type(Symbol()) == 'object' // true => it's a error

$.type(Symbol()) // symbol .....

// Populate the class2type map $.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "), function(i, name) { class2type[ "[object " + name + "]" ] = name.toLowerCase() })