JQuery.type 和 typeof 的区别,哪个更快 [英] Difference between JQuery.type and typeof, which is faster
本文介绍了JQuery.type 和 typeof 的区别,哪个更快的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个名为 processData 的方法,其中我使用了以下代码来检查变量的类型
I have a method called processData, in which i have used the below code to check the type of the variable
typeof series.dataSource.xName == "string"
jQuery.type(series.dataSource.xName)=="string"
我不知道哪个更快,执行时间更短,整体类型"需要55毫秒来执行,我需要优化它
i what to know which is faster, and will take less time to execute, overall "type" need 55ms to execute, i need to optimize it
提前致谢
推荐答案
这是你的答案 详细查看....
This is your answer See in Detail....
这篇关于JQuery.type 和 typeof 的区别,哪个更快的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文