上一页 1 ··· 457 458 459 460 461 462 463 464 465 ··· 467 下一页
摘要: Let's take a closer look at how a browser retrieves and acts on scripts.modern browser can parallel downloading 6 files(style sheets && images)at a ti 阅读全文
posted @ 2014-08-12 20:42 Zhentiw 阅读(245) 评论(0) 推荐(0) 编辑
摘要: /** Improve you loop code */ var treasureChest = { goldCoins: 10000, magicalItem : "Crown of Speed", necklaces: ["ruby", "pearl", "sapphire", "diamond 阅读全文
posted @ 2014-08-12 20:26 Zhentiw 阅读(214) 评论(0) 推荐(0) 编辑
摘要: Refactor the spacing between <header>, <article>, and <aside> so that elements will have a 20px margin above and below, regardless of their order on t 阅读全文
posted @ 2014-08-11 04:43 Zhentiw 阅读(162) 评论(0) 推荐(0) 编辑
摘要: /** Ternary Conditionals */ // //**Bad** // var isArthur = false; var weapon; if(isArthur){ weapon = "Excalibur"; }else{ weapon = "Longsword"; } // // 阅读全文
posted @ 2014-08-11 03:45 Zhentiw 阅读(157) 评论(0) 推荐(0) 编辑
摘要: Sometime, use can rewrite the toString , valueOf method to make those function more useful: For exmaple, we can make valueOf() function to calcualte t 阅读全文
posted @ 2014-08-11 02:53 Zhentiw 阅读(227) 评论(0) 推荐(0) 编辑
摘要: function Fencepost (x, y, postNum){ this.x = x; this.y = y; this.postNum = postNum; this.connectionsTo = []; } Fencepost.prototype = { sendRopeTo: fun 阅读全文
posted @ 2014-08-10 17:59 Zhentiw 阅读(163) 评论(0) 推荐(0) 编辑
摘要: You can add prototype to any object in Jacascript likes Object, Array, String... prototype 有继承的作用,比如说我有一个String的对象,我可以访问Object的prototype hasPrototype( 阅读全文
posted @ 2014-08-10 02:32 Zhentiw 阅读(177) 评论(0) 推荐(0) 编辑
摘要: Convert the AppointmentForm view below to use Mustache templating. Make sure you remember to change the <%= %> placeholders with Mustache's {{}} place 阅读全文
posted @ 2014-08-09 17:52 Zhentiw 阅读(180) 评论(0) 推荐(0) 编辑
摘要: Our first step is to add a template to the AppointmentForm below. Have the template produce a form with two inputs, one for the title of the appointme 阅读全文
posted @ 2014-08-09 03:25 Zhentiw 阅读(176) 评论(0) 推荐(0) 编辑
摘要: Below we have our AppointmentsView instance rendering and then taking the rendered HTML and inserting into the$('#app') element. Change the code to in 阅读全文
posted @ 2014-08-08 22:35 Zhentiw 阅读(167) 评论(0) 推荐(0) 编辑
上一页 1 ··· 457 458 459 460 461 462 463 464 465 ··· 467 下一页