61- 插件使用案例-城市联动
<!DOCTYPE html>
<html lang="en">
<head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><title>城市联动</title>
</head>
<body><div id="one"><select name="" ></select><select name="" ></select><select name="" ></select></div>
</body><script src="https://s3.pstatp.com/cdn/expire-1-M/jquery/3.3.1/jquery.min.js"></script>
<script src="plugins/distpicker.data.js"></script>
<script src="plugins/distpicker.js"></script>
<script>$(function name(params) {//使用插件//1.引入jQuery文件//2.引入插件文件//3.调用插件方法$('#one').distpicker();})
</script>
</html>
63-自己封装插件
$.method = fn //静态方法$.fn.method = fn //实例方法