码迷,mamicode.com
首页 > 编程语言 > 详细

jQuery对象就是伪数组

时间:2020-03-01 20:18:32      阅读:91      评论:0      收藏:0      [点我收藏+]

标签:set   对象   html   fun   src   type   div2   charset   div   

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>07-jQuery对象</title>
<script src="../js/jquery-3.4.1.js"></script>
<script>
$(function () {
var $div= $("div");
console.log($div);
//什么是jQuery对象 jQuery对象是一个伪数组
//什么是伪数组 有0到length-1且有length属性
var arr=[1,3,5];
console.log(arr);

})

</script>
</head>
<body>
<div>div1</div>
<div>div2</div>
<div>div3</div>
</body>
</html>

jQuery对象就是伪数组

标签:set   对象   html   fun   src   type   div2   charset   div   

原文地址:https://www.cnblogs.com/god1/p/12391266.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!