摘要: <style> [v-cloak]{ display: none; } </style> <body> <div id="app"> <h1 v-cloak>{{ msg }}</h1> </div> 过程: 1 通过 CSS样式将 带有 v-cloak 属性的元素隐藏 2 这样,我们就无法看到 { 阅读全文
posted @ 2018-08-26 16:07 cecelingmeng 阅读(144) 评论(0) 推荐(0) 编辑
摘要: swiper在vue里的用法 首先通过npm i vue-awesome-swiper --save 来在vue中下载插件 然后再main.js中引入 require('swiper/dist/css/swiper.css')import VueAwesomeSwiper from 'vue-awe 阅读全文
posted @ 2018-08-23 14:09 cecelingmeng 阅读(91) 评论(0) 推荐(0) 编辑
摘要: // 添加 .self 修饰符后,只有点击绑定事件元素本身才会触发这个事件,点击子元素是不回触发这个事件的 <div class="dv" @click.self="handleClick"> <button>按钮</button> </div> // 添加 .self 修饰符后,只有点击绑定事件元 阅读全文
posted @ 2018-08-07 22:46 cecelingmeng 阅读(72) 评论(0) 推荐(0) 编辑
摘要: 1: <style> .green{background-color:black} .size{fount-size:18px} </style> 2: <body> <div id="app"> <div :class="cls">天上的星</div> <div :class="{ green: 阅读全文
posted @ 2018-08-07 22:20 cecelingmeng 阅读(146) 评论(0) 推荐(0) 编辑
摘要: // 数组 var trees = new Array("redwood", "bay", "cedar", "oak", "maple"); 0 in trees // 返回true 3 in trees // 返回true 6 in trees // 返回false "bay" in trees 阅读全文
posted @ 2018-07-27 10:58 cecelingmeng 阅读(797) 评论(0) 推荐(0) 编辑
只有注册用户登录后才能阅读该文。 阅读全文
posted @ 2018-07-19 14:39 cecelingmeng 阅读(2) 评论(0) 推荐(0) 编辑
只有注册用户登录后才能阅读该文。 阅读全文
posted @ 2018-07-19 14:07 cecelingmeng 阅读(0) 评论(0) 推荐(0) 编辑