1.安装
使用软件:webSrorm
安装路径:H:\1学习资料\1前端\Jquery\train>
安装过程:在H:\1学习资料\1前端\Jquery\train所在的Webstorm的Terminal窗口中输入npm install jquery
出现`-- jquery@3.2.1
安装成功
2.验证
在trian文件夹中新建test.html,进行测试
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>测试jQuery</title> <script src="jquery/dist/jquery.js"> </script> <script> $(document).ready(function(){ $("p").click(function(){ $(this).hide(); }); }); </script> </head> <body> <p>如果你点我,我就会消失。</p> <p>继续点我!</p> <p>接着点我!</p> </body> </html>