Ruby Sandi Metz:简化代码的三招

chenge · 2014年05月25日 · 最后由 Msms 回复于 2014年05月26日 · 1561 次阅读

来自本周的 rubyweekly,作者是那本 RubyOO 书的作者。

  • 小代码
  • 重复再重构
  • 代码形态和色彩

Keep it small, duplicate until it makes sense and refactor into simplicity, and follow the shape and pattern of your code.

http://multifaceted.io/2014/3-simple-but-powerful-takeaways-from-sandi-metz/?utm_source=rubyweekly&utm_medium=email

重构演示 https://speakerdeck.com/skmetz/all-the-little-things-rubyonales

:plus1: 感觉 DRY 那里说的很好,Dare to Repeat yourself then Refactor

mark 下,

需要 登录 后方可回复, 如果你还没有账号请 注册新账号