上一页 1 ··· 17 18 19 20 21 22 23 24 25 ··· 44 下一页
摘要: 用一个链接进行用户的注册推广: 我的git: https://github.com/chentianwei411/embeddable_comments 用途:比如推广,拉朋友注册,给推广码,用这个码注册就知道是谁推广的了。 使用这个链接注册的用户,它的user记录中的referred_by_id会 阅读全文
posted @ 2018-10-19 19:24 Mr-chen 阅读(441) 评论(0) 推荐(0) 编辑
摘要: https://github.com/stimulusjs/stimulus 一个现代JS框架,不会完全占据你的前端,事实上它不涉及渲染HTML。 相反,它被设计用于增加你的HTML和刚刚够好的behavior。 Stimulus和Turbolinks协作非常好。 Stimulus is a Jav 阅读全文
posted @ 2018-10-17 20:29 Mr-chen 阅读(536) 评论(0) 推荐(0) 编辑
摘要: 建立一个嵌套的评论 视频1 https://gorails.com/episodes/nested-comment-threads-in-rails-part-1?autoplay=1 目标:建立数据库结构,和嵌套视图。 方法概览: 1. 建立一个可以自我关联的comment的表结构。 2. 建立p 阅读全文
posted @ 2018-10-17 09:36 Mr-chen 阅读(434) 评论(0) 推荐(0) 编辑
摘要: 由于状态零散地分布在许多组件和组件之间的交互中,大型应用复杂度也经常逐渐增长。 如果多层组件嵌套使用,传递prop,和事件emit。都很不方便。 不方便对数据的修改进行历史记录。影响后续的调试! 为了解决这个问题,Vue 提供 vuex。 vuex 甚至集成到 vue-devtools,无需配置即可 阅读全文
posted @ 2018-10-13 12:23 Mr-chen 阅读(3787) 评论(0) 推荐(1) 编辑
摘要: Chapter 3: Promises But what if we could uninvert that inversion of control? What if instead of handing the continuation of our program to another par 阅读全文
posted @ 2018-10-11 18:03 Mr-chen 阅读(249) 评论(0) 推荐(0) 编辑
摘要: Chapter 2: Callbacks. Callbacks are by far the most common way that asynchrony in JS programs is expressed and managed. Indeed, the callback is the mo 阅读全文
posted @ 2018-10-11 10:07 Mr-chen 阅读(245) 评论(0) 推荐(0) 编辑
摘要: Chapter 1: Asynchrony: Now & Later 在一门语言中,比如JavaScript, 最重要但仍然常常被误解的编程部分是如何在一个完整的时间周期表示和操作程序行为。 这是关于当你的程序正在部分运行,其他部分等待运行。--这之间的gap。 mind the gap!(比如在s 阅读全文
posted @ 2018-10-10 10:26 Mr-chen 阅读(354) 评论(0) 推荐(0) 编辑
摘要: 本章深挖原型机制。 [[Prototype]]比类更直接和简单! https://github.com/getify/You-Dont-Know-JS/blob/master/this%20%26%20object%20prototypes/ch6.md 这个实际的机制,都是关于对象之间的连接,一个 阅读全文
posted @ 2018-10-09 21:19 Mr-chen 阅读(220) 评论(0) 推荐(0) 编辑
摘要: qu上章提到过[[prototype]] chain, 本章详细分析 ⚠️所有试图模仿类复制的行为,如上章提到的mixins的变种,完全规避了[[Prototype]] chain机制,本章会谈到这方面 [[Prototype]] 一个特别的内建属性。用于引用到其他对象。当对象创建后,会得到一个这个 阅读全文
posted @ 2018-10-08 09:17 Mr-chen 阅读(214) 评论(0) 推荐(0) 编辑
摘要: 本章移到“Object oriented programming”和"classes"。 看‘class orientation‘ 的设计模式: instantiation, inheritance, relative 多态性。 会重点讲解oop理论,当讲到Mixins, 我们会最终联系这些思想到真 阅读全文
posted @ 2018-10-07 16:31 Mr-chen 阅读(100) 评论(0) 推荐(0) 编辑
上一页 1 ··· 17 18 19 20 21 22 23 24 25 ··· 44 下一页