5 FaceBook Source Code Secrets 5 Facebook的源代碼的秘密
I glanced over the Facebook source code for both index and search pages. i glanced超過Facebook的源代碼都索引和搜索的頁面。 As an enterprise developer of some experience, source code is always interesting to me as it provides an insight into the health of a company.作為一個企業開發的一些經驗,源代碼始終是有趣的我,因為它提供了一個洞察到健康的一間公司。 The interesting highlights of the Facebook code are:有趣的重點Facebook的代碼是:
1. 1 。 Facebook writes pretty clean code & maintains coding standards. Facebook的寫漂亮的清潔守則&保持編碼標準。 The code is readable.代碼是可讀性。
2. 2 。 To Facebook coder: Calling a function to do the magic isn’t an example of clean code; in response to Facebook coders comment - “Holy shit, is this the cleanest fucking frontend file you’ve ever seen”以Facebook的編碼器:電話的功能,這樣做是不是魔術的一個例子,清潔守則;在回應Facebook的編碼評論-“聖s hit外圍,這是最清潔的他媽的前端文件,你所見過的” 。
3. 3 。 Facebook doesn’t do MVC. Facebook的不MVC的。 There isn’t any separation of concerns as far as I could see.有沒有任何分離的關注,據我可以看到。 It is also not a designer’s job.這亦是不是一個設計師的工作。 It is created by developers with tons of procedural PHP code.這是所創造的發展與噸的程序PHP代碼。
4. 4 。 Facebook also doesn’t do much object oriented coding either, at least it wasn’t apparent from these source files. Facebook的,也沒有做很多面向對象的編碼或者,至少它並不明顯,從這些源文件。 It is plain and simple procedural code.這是平原和簡單的程序代碼。
5. 5 。 Facebook uses templates which is nice. Facebook的使用模板,這是很好。
It does some interesting stuff with advertising, specifically estimates the length of page and attributes to determine advertisements to show.它的一些有趣的東西與廣告,特別是估計的長度頁和屬性,以確定廣告的顯示。 There are few interesting ideas here.有幾個有趣的想法在這裡。
Did you expect more?你期望更多? There isn’t much more really, take a look yourself.有沒有更實在,考慮一下自己。 I wonder if MySpace’s code is as clean.我不知道如果MySpace上的代碼是作為清潔。
Filed under提起下 Facebook臉譜 , , Headline News頭條新聞 , , MySpace MySpace上 , , PHP PHP的 , , Programming編程 , , Social Networking社會網絡 , , Web網頁 , , Web 2.0 Web 2.0的 , , Web Services Web服務 | |
| |
RSS 2.0 2.0 | |
Trackback Trackback跟踪 this Article |此文章|
Email this Article電子郵件此文章
You may also like to read您也可以想讀 |




