星期一, 4月 07, 2008

javascript 撰寫觀念

這篇的標題是"ASP.NET AJAX Best Practices"看起來好像在討論ajax的東西..
不過內容在談javascript的撰寫觀念..我覺得寫的很不錯..就推薦給大家看啦..
裡面有幾個重點..

  1. Use more "var"
  2. Reduce scopes
  3. Careful with DOM element concatenation
  4. Avoid using your own method while there is one
  5. Avoid using Array.length in a loop
  6. Avoid String concatenation, use Array instead
  7. Introduce function delegates
  8. Introduce DOM elements and function caching
  9. Problem with switch

這幾個標題都很有用的..有空看一看ㄅ..

ps:看不懂怎辦..翻譯機按一按阿..不然還能怎辦..Hot

沒有留言: