jQuery.type()方法
jQuery 教程
· 2019-03-29 11:38:50
实例
该参数是否一个正则表达式
这是一个正则表达式? <b></b>
<script>
$(function () {
$( "b" ).append( "" + jQuery.type( /test/ ) );
})
</script>
定义和用法
$.type() 函数用于确定JavaScript内置对象的类型,并返回小写形式的类型名称。
如果对象是undefined或null,则返回相应的"undefined"或"null"
$.type( undefined ) === "undefined" $.type() === "undefined" $.type( window.notDefined ) === "undefined" $.type( null ) === "null"
如果对象有一个内部属性[[Class]]和一个浏览器的内置对象的 [[Class]] 相同,我们返回相应的 [[Class]] 名字。
$.type( true ) === "boolean"
$.type( 3 ) === "number"
$.type( "test" ) === "string"
$.type( function(){} ) === "function"
$.type( [] ) === "array"
$.type( new Date() ) === "date"
$.type( new Error() ) === "error" // jQuery 1.9 新增支持
$.type( /test/ ) === "regexp"
语法
$.type( obj )
| 参数 | 描述 |
|---|---|
| obj | 任意类型 需要确定类型的任意对象。 |
点击查看所有 jQuery 教程 文章: https://codercto.com/courses/l/35.html
数据化运营速成手册
胡晨川 / 电子工业出版社 / 2017-4 / 55
《数据化运营速成手册》用于提升互联网公司员工的数据应用能力,即数据化运营能力。首先,从最常用的数据图表切入,帮助执行层正确地绘图,管理层正确地看图;接着,梳理运营中最基本的数据应用知识,涉及数据获取、数据清洗、数据认知、分析框架、指标体系、运营实验等内容。然后,介绍作者认为必要的统计学知识,包括假设检验、方差分析、回归分析和时间序列分解,并引入了管理科学中的规划求解方法。最后,介绍了数据分析工具的......一起来看看 《数据化运营速成手册》 这本书的介绍吧!