Ext.isNumber:

 1 Ext.isNumber(1)
 2 true
 3 Ext.isNumber(new Number(1))
 4 false
 5 Ext.isNumber("1")
 6 false
 7 
 8 Ext.isNumber(Number.MAX_VALUE)
 9 true
10 Ext.isNumber(Number.MIN_VALUE)
11 true
12 
13 Ext.isNumber(Number.POSITIVE_INFINITY)
14 false
15 Ext.isNumber(Number.NEGATIVE_INFINITY)
16 false

Ext.isNumeric:

SRE实战 互联网时代守护先锋,助力企业售后服务体系运筹帷幄!一键直达领取阿里云限量特价优惠。
 1 Ext.isNumeric(1)
 2 true
 3 Ext.isNumeric(new Number(1))
 4 true
 5 Ext.isNumeric("1")
 6 true
 7 
 8 Ext.isNumeric(Number.MAX_VALUE)
 9 true
10 Ext.isNumeric(Number.MIN_VALUE)
11 true
12 
13 Ext.isNumeric(Number.POSITIVE_INFINITY)
14 false
15 Ext.isNumeric(Number.NEGATIVE_INFINITY)
16 false

区别在于:

对于数字对象、数字字符串

Ext.isNumber返回false;而Ext.isNumeric返回true

扫码关注我们
微信号:SRE实战
拒绝背锅 运筹帷幄