JQuery

JQuery is a fast, small, and feature-rich JavaScript library.

It makes things like HTML document traversal and manipulation, event handling, animation, and Ajax much simpler with an easy-to-use API that works across a multitude of browsers.

With a combination of versatility and extensibility, jQuery has changed the way that millions of people write JavaScript.

快速开始

<!DOCTYPE html>
<html>
<head>
<script src="https://cdn.staticfile.org/jquery/1.10.2/jquery.min.js"></script>
<script>
$(document).ready(function(){
  $("button").click(function(){
    $("#hidden-p").hide();
  });
});
</script>
</head>

<body>
<h2>这是一个标题</h2>
<p>这是一个段落。</p>
<p id="hidden-p">点击我就不见了,注意点。</p>
<button>点我</button>
</body>
</html>

示例页面

这是一个标题

这是一个段落。

点击我就不见了,注意点。

拓展阅读

前端 Boostrap

手写 jQuery 插件

参考资料

手写 JQuery 框架

jquery 入门教程