上一页 1 2 3 4 5 6 ··· 18 下一页

2019年7月22日

vue打开到新页面,并传递参数

摘要: 打开新页面,有两种方式, 一种是标签式: <router-link tag="a" target="_blank" :to="{path: '/edit', params: {id: '000'}}"> 一种是函数编程式: let routeData = this.$router.resolve({ 阅读全文

posted @ 2019-07-22 16:24 王子乔 阅读(9531) 评论(0) 推荐(1) 编辑

2019年5月30日

彻底了解websocket原理

摘要: 一、websocket与http WebSocket是HTML5出的东西(协议),也就是说HTTP协议没有变化,或者说没关系,但HTTP是不支持持久连接的(长连接,循环连接的不算) 首先HTTP有 1.1 和 1.0 之说,也就是所谓的 keep-alive ,把多个HTTP请求合并为一个,但是 W 阅读全文

posted @ 2019-05-30 11:19 王子乔 阅读(295) 评论(0) 推荐(0) 编辑

2019年4月29日

bind和on的区别

摘要: bind方法与on方法都是事件绑定,但是两者却又有着一个大区别:事件委托 jquery文档中bind和on函数绑定事件的用法: .bind(events [,eventData], handler) .on(events [,selector] [,data], handler) 从文档中可以看出, 阅读全文

posted @ 2019-04-29 14:29 王子乔 阅读(855) 评论(0) 推荐(0) 编辑

2019年4月25日

Vue如何更新子组件

摘要: 黑科技: 给子组件绑定一个key值,当key值改变时,子组件就会更新 ~ 阅读全文

posted @ 2019-04-25 16:25 王子乔 阅读(4456) 评论(1) 推荐(0) 编辑

Vue父子组件生命过程

摘要: 加载渲染过程 父beforeCreate->父created->父beforeMount->子beforeCreate->子created->子beforeMount->子mounted->父mounted 子组件更新过程 父beforeUpdate->子beforeUpdate->子updated 阅读全文

posted @ 2019-04-25 11:44 王子乔 阅读(142) 评论(0) 推荐(0) 编辑

2019年4月18日

使用css3实现动画来开启GPU加速

摘要: 参考文章: https://www.w3cplus.com/css3/introduction-to-hardware-acceleration-css-animations.html http://blog.csdn.net/hsany330/article/details/50925260 用C 阅读全文

posted @ 2019-04-18 15:06 王子乔 阅读(4261) 评论(0) 推荐(0) 编辑

2019年3月20日

前端技术体系

摘要: 一、前端技术框架 官网:https://cn.vuejs.org/ Vue CLI:https://cli.vuejs.org/ 菜鸟教程:http://www.runoob.com/w3cnote... Nuxt.js:https://zh.nuxtjs.org/ 桌面应用Electron:htt 阅读全文

posted @ 2019-03-20 09:30 王子乔 阅读(746) 评论(0) 推荐(0) 编辑

2019年3月18日

Vue中的~(静态资源处理)

摘要: Webpacked 资源 首先要理解webpack是怎样处理静态资源的。 在*.vue组件中,所有的templates和css都会被vue-html-loader 和 css-loader解析,寻找资源的URL。 举个例子,在<img src="./logo.png"> 和 background: 阅读全文

posted @ 2019-03-18 15:09 王子乔 阅读(1079) 评论(0) 推荐(0) 编辑

2019年2月20日

垂直居中的办法小结

摘要: 单行文本的话可以使用height和line-height设置同一高度。 position+margin:设置父元素:position: relative;,子元素height: 100px; position:absolute;top: 50%; margin: -50px 0 0 0;(定高) p 阅读全文

posted @ 2019-02-20 16:26 王子乔 阅读(99) 评论(0) 推荐(0) 编辑

forEach() 和 map() 遍历

摘要: 1.forEach() 没有返回值。 arr[].forEach(function(value,index,array){ //do something }) 参数:value数组中的当前项, index当前项的索引, array原始数组; 数组中有几项,那么传递进去的匿名回调函数就需要执行几次; 阅读全文

posted @ 2019-02-20 15:10 王子乔 阅读(469) 评论(0) 推荐(0) 编辑

上一页 1 2 3 4 5 6 ··· 18 下一页

导航