<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>jq之demo</title> <!--线上jq库--> <script src="https://code.jquery.com/jquery-3.4.1.min.js"></script> <script> $(document).ready(function(){ $("button").click(function(){ /*function()为回调函数在slow执行完后执行*/ $("p").hide("slow",function(){ alert("段落隐藏"); }); }); }); </script> </head> <body> <button>隐藏</button><br/> <p>段落</p> </body> </html>
03-12
708
