![](https://img-blog.csdnimg.cn/20201014180756780.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
jquery
飞啊飞我的骄傲放纵-未来全栈工程师
四年前端小白
展开
-
vue.js 引入 配置 jquery
安装依赖 npm install jquery --save 打开webpack.prod.conf.js 文件 找到plugins:[ ],配置jquery plugins:[ new webpack.ProvidePlugin({ $:'jquery', jQuery:"jquery", jquery:"jquery", "window.jQuery":"jquery" }) ] 在需要使用jQuery组件的sc原创 2021-03-03 17:16:21 · 197 阅读 · 1 评论 -
jquery 监听 页面 滚动 到底部 顶部
$(function () { $('.main').scroll(function () { var scroH = $('.main').scrollTop(); //滚动高度 console.log(scroH); var viewH = $('.main').height(); //可见高度 console.log(viewH); v转载 2020-12-04 12:34:23 · 350 阅读 · 0 评论 -
js input 上传 图片
//个人动态图片 上传 $("#dynamic").change(function () { let file = $(this).get(0).files[0]; // console.log(file); if (file.type == 'image/png' || file.type == 'image/jpeg') { var fileType = console.log(file.type); ...原创 2020-08-06 20:56:22 · 259 阅读 · 0 评论 -
登录页面 正则 匹配 只匹配数字 或者 数字加字母
jq 写法 如下 // An highlighted block let str; let value; $('#user').bind('input propertychange', function() { str = $(this).val(); console.log(str); value = str.replace(/\D/g,""); $(this).原创 2020-07-17 20:25:09 · 192 阅读 · 0 评论