05 2020 档案

摘要:<template> <div> <span>原生scroll滚动</span> <div class="box1"> <ul> <li><img src="https://img.alicdn.com/imgextra/i2/4095915205/O1CN01PqDzxg1oJw73HQqG6_! 阅读全文
posted @ 2020-05-31 17:36 hongwj 阅读(163) 评论(0) 推荐(0) 编辑
摘要:一、String 的属性 1.1 length 属性 获取字符串的长度,需要特别注意的是:JavaScript 中的中文每个汉字也只代表一个字符,可能跟其他语言不同。 '中国'.length // 2 1.2 prototype 属性 在 OOP 中经常用到,用来给对象添加属性或方法,且添加的属性或 阅读全文
posted @ 2020-05-27 09:01 hongwj 阅读(1516) 评论(0) 推荐(0) 编辑
摘要:<template> <div class="about"> <h1>about page</h1> <el-row> <el-col :span="2"><div class="grid-content bg-purple">11</div></el-col> <el-col :span="22" 阅读全文
posted @ 2020-05-21 23:05 hongwj 阅读(200) 评论(0) 推荐(0) 编辑
摘要:<template> <div> <div class="change"> <p :class="selecttab== 'all'?'selected':'unSelected'" @click="hadleclick(1)">全部</p> <p @click="hadleclick(2)" :c 阅读全文
posted @ 2020-05-18 13:10 hongwj 阅读(482) 评论(0) 推荐(0) 编辑
摘要:在项目中有时候会遇到要求输入的数字是整数或者小数点后绑定2位小数,因此可以用.toFixed(2)方法 下面是关于toFixed()方法的demo; 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 <input type="number" value="" class= 阅读全文
posted @ 2020-05-16 19:34 hongwj 阅读(191) 评论(0) 推荐(0) 编辑
摘要:<template> <div> <span>{{num | filteradd}}</span> //¥2.1万 </div> </template> <script> export default { data(){ return { num:21000 } }, props:['name',' 阅读全文
posted @ 2020-05-16 19:23 hongwj 阅读(130) 评论(0) 推荐(0) 编辑
摘要:首先下载字体图标 地址:http://www.font5.com/download.php?id=15110&designated=1274799300 下载完之后放在assets中 在app.vue 中声明字体 @font-face { font-family: electronicFont; s 阅读全文
posted @ 2020-05-15 17:00 hongwj 阅读(640) 评论(0) 推荐(0) 编辑
摘要:<template> <div> <div class="textBox"> <transition name="slide"> <p class="text" :key="text.id"> <el-tag type="warning">{{text.val.tag}}</el-tag> {{te 阅读全文
posted @ 2020-05-13 14:17 hongwj 阅读(9378) 评论(2) 推荐(2) 编辑
摘要:如何正确修改element组件样式 强调一点,>>>三箭头穿透函数,要在配合scoped一起使用。 image.png image.png sass样式穿透要使用 /deep/ 使用三箭头无效 .choosetime /deep/ .el-date-editor .el-range-input{ w 阅读全文
posted @ 2020-05-12 10:37 hongwj 阅读(885) 评论(0) 推荐(0) 编辑
摘要:<div :class="{icontant:tr}"> <div class="iconts2"> <div :class="{chcolor:iscolor}"><span>今天:</span> <span>2020.5.6</span> </div> <div :class="{chcolor 阅读全文
posted @ 2020-05-11 13:57 hongwj 阅读(909) 评论(0) 推荐(0) 编辑
摘要:var arr = [ 'a', 'b', 'c' ]; // 1. push (在数组最后再添加一个元素) arr.push('jirengu') //再数组最后添加一个元素 console.log(arr) const a =[1,2,3,4,5,6] console.log([...arr,. 阅读全文
posted @ 2020-05-11 11:55 hongwj 阅读(295) 评论(0) 推荐(0) 编辑
摘要:1.创建variable.scss 文件 // 颜色 $color-red:red; $color-yellow: yellow; $color-white: white; $color-light-gray: #F5F5F5; 2.创建 vue.config.js 添加 css: { loader 阅读全文
posted @ 2020-05-10 18:14 hongwj 阅读(2300) 评论(0) 推荐(0) 编辑