摘要: 在需要使用的HTML中使用[(ngModel)]进行数据绑定: <div> <span>name:</span> {{hero.name}}</div> <div> <label> name: <input [(ngModel)]="hero.name" placeholder="name"> </ 阅读全文
posted @ 2019-12-02 12:02 咱也不敢问 阅读(475) 评论(0) 推荐(0) 编辑
摘要: 一、创建分支,并提交 1、git branch 分支名,(创建分支) 2、git checkout -b 分支名 创建并切换分支 3、git status 查看状态 4、git add . 提交所有的分支内容,把分支内容添加到git仓库中暂存 5、git commit -m '提交的内容简单介绍' 阅读全文
posted @ 2019-11-15 15:36 咱也不敢问 阅读(137) 评论(0) 推荐(0) 编辑
摘要: 优点:1、对象的状态不受外界的影响,只有异步操作的结果可以决定是那种状态;2、状态一旦改变,就不会再次改变。任何时候都可以得到这个结果。在这里跟(event)事件不同,如果错过了这个事件结果再去监听,是监听不到event事件的。 缺点:1、promise一旦执行无法取消。2、如果不设置回调函数pro 阅读全文
posted @ 2019-11-06 11:29 咱也不敢问 阅读(2468) 评论(0) 推荐(0) 编辑
摘要: 1、父传子 传参页面 <template> <div id="app"> <p>父组件</p> <users :users="users"></users>//在父组件中显示子组件,将要传递的值绑定到子组件上 </div> </template> <script> import Users from 阅读全文
posted @ 2019-10-30 11:53 咱也不敢问 阅读(198) 评论(0) 推荐(0) 编辑
摘要: 1、params传参页面 <template> <button @click="params()">params传参</button> </template> <script> export default { </template> <script> export default { export 阅读全文
posted @ 2019-10-30 11:03 咱也不敢问 阅读(324) 评论(0) 推荐(0) 编辑
摘要: 首先,准备两个div盒子,给每个盒子设置固定的宽高,但是在设置宽度时给子盒子的宽度设置高于父盒子30px, <style> .box { height: 200px; width: 200px; overflow: hidden; } .boxSon { width: 230px; height:  阅读全文
posted @ 2019-10-28 15:19 咱也不敢问 阅读(156) 评论(0) 推荐(0) 编辑
摘要: <div class="refresh">刷新</div> <script> // 鼠标按下$('.refresh').mousedown(function () { $(this).css({ "color": "#2a72f5" })})// 鼠标抬起$('.refresh').mouseup( 阅读全文
posted @ 2019-10-23 15:15 咱也不敢问 阅读(374) 评论(0) 推荐(0) 编辑
摘要: 暂停直播 开始直播 var pause = true; // 点击暂停直播按钮暂停 $('.stop').click(function () { if (pause) { pause = false $('video').trigger('pause'); $('.p1').css({... 阅读全文
posted @ 2019-10-23 11:38 咱也不敢问 阅读(1660) 评论(0) 推荐(0) 编辑
摘要: $("div").text(); 获取中间的文本,不包括html标签; $("div").html(); 获取中间的所有内容。 $('textarea').val();获取输入的内容 阅读全文
posted @ 2019-10-23 11:33 咱也不敢问 阅读(745) 评论(0) 推荐(0) 编辑
摘要: function Time() { var now = new Date(); var year = now.getFullYear(); //年 var month = now.getMonth() + 1; //月 var day = now.getDate(); //日 var hh = no 阅读全文
posted @ 2019-10-21 18:28 咱也不敢问 阅读(846) 评论(0) 推荐(0) 编辑