上一页 1 2 3 4 5 6 7 ··· 13 下一页
摘要: &是less、sass的语法,是一种连接符。 .el-row { margin-bottom: 20px; &:last-child { margin-bottom: 0; } } sass语法,等同于: .el-row { margin-bottom: 20px; } .el-row:last-c 阅读全文
posted @ 2022-04-26 19:23 ZJTL 阅读(738) 评论(0) 推荐(0) 编辑
摘要: 同事问我这个怎么用,我还真没见过,所以网上找了一篇讲的很详细的文章。 $attrs是在vue的2.40版本以上添加的。 项目中有多层组件传参可以使用$attrs,可以使代码更加美观,更加简洁,维护代码的时候更方便。如果使用普通的父子组件传参props和$emit,$on会很繁琐;如果使用vuex会大 阅读全文
posted @ 2022-04-26 17:07 ZJTL 阅读(651) 评论(0) 推荐(0) 编辑
摘要: 使用 transform: scaleY() 缩放来实现,即将Y轴缩小至原来的0.5倍来达到一个0.5px的效果: .line:after { content: ''; position: absolute; bottom: 0; height: 1px; width: 100%; backgrou 阅读全文
posted @ 2022-04-26 15:37 ZJTL 阅读(155) 评论(0) 推荐(0) 编辑
摘要: 安装: npm install vue-video-player --save main.js中配置: import VideoPlayer from 'vue-video-player' import 'video.js/dist/video-js.css' import 'vue-video-p 阅读全文
posted @ 2022-01-17 10:45 ZJTL 阅读(1028) 评论(0) 推荐(0) 编辑
摘要: 安装: npm install --save vue-pdf Demo: <template> <div> <pdf ref="pdf" :src="url"> </pdf> </div> </template> <script> import pdf from 'vue-pdf' export d 阅读全文
posted @ 2022-01-12 14:00 ZJTL 阅读(357) 评论(0) 推荐(0) 编辑
摘要: 坑了我一个小时,直接上代码: <el-table :header-cell-style="{background:'#eee',color:'#606266'}"> ... </el-table> header-cell-style是表头单元格的 style 的回调方法,也可以使用一个固定的 Obj 阅读全文
posted @ 2021-12-21 16:05 ZJTL 阅读(1452) 评论(0) 推荐(0) 编辑
摘要: 加载渲染过程 ->父beforeCreate -> 父created -> 父beforeMount ->子beforeCreate -> 子created -> 子beforeMount -> 子mounted -> 父mounted 子组件更新过程 ->父beforeUpdate -> 子bef 阅读全文
posted @ 2021-11-03 15:41 ZJTL 阅读(92) 评论(0) 推荐(0) 编辑
摘要: 一、什么是浅拷贝 在js当中,我们常常遇到数组复制的的情况,许多人一般都会使用“=”来直接把一个数组赋值给一个变量,如 1 var a=[1,2,3]; 2 var b=a; 3 console.log(b); //输出的是1,2,3 4 a[2]=0; 5 console.log(b); //输出 阅读全文
posted @ 2021-11-03 11:14 ZJTL 阅读(1635) 评论(0) 推荐(1) 编辑
摘要: Array.prototype.map()和Array.prototype.forEach() forEach(): 针对每一个元素执行提供的函数 map(): 创建一个新的数组,其中每一个元素由调用数组中的每一个元素执行提供的函数得来 到底有什么区别呢?forEach()方法不会返回执行结果,而是 阅读全文
posted @ 2021-11-03 10:58 ZJTL 阅读(159) 评论(0) 推荐(0) 编辑
摘要: 规则 以数字字母开头,中间可以是多个数字字母下划线或‘-’,或‘.’然后是 “@”符号,后面是数字字母然后是“.”符号,后面是2-6个字母结尾 xxxx@xxx.com xxxx@xxx.com.cn xxxx.xxxxx@xxx.com /^([a-zA-Z\d])((\w|-)+\.?)+@([ 阅读全文
posted @ 2021-08-31 15:16 ZJTL 阅读(262) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 ··· 13 下一页