假如让你写一个排序,你会怎么写呢?for循环搞定吗?来看下边这个是怎么实现的:function quickSort(arr){ if(arr.length<=1){ return arr; } var num = Math.floor(... Read More
posted @ 2015-12-09 22:31 丶More Views(168) Comments(0) Diggs(0)
在看叶小钗的博客。。跟着他的范例做。。看到有一个小的设计模式吧。。先上代码 通讯录 姓名: ... Read More
posted @ 2015-11-29 21:59 丶More Views(148) Comments(0) Diggs(0)
说道Backbone的事件机制。自己也是逗逼了。敲了一遍Backbone的源码。。居然是还不知道他的机制。。先上Events On对象的源码/** * Created by More on 2015/11/28. */var Events = Backbone.Events ={ /** ... Read More
posted @ 2015-11-28 20:42 丶More Views(197) Comments(0) Diggs(0)
这两天把Backbone源代码敲了一遍。熟悉了内部的运行机制。。就开始干Backbone了。。初来乍到、不喜勿喷、喜大普奔~~跑到叶小钗的博客里边找了一些源代码。。感觉超级实用先来扯下我了解的Backbone1.Model、Collection、View静态属性没有多少,全部丢在原型里边,三个对象靠... Read More
posted @ 2015-11-28 19:13 丶More Views(152) Comments(0) Diggs(0)