git add 前,要記得先看一下 git status ,不需要 commit 的就不要加入。

git commit 之前,要確認一下 .gitignore ,以免把 test 或是 database 的資料也丟上去了。

工作平台上的 rails 指令,要記得加上 RAILS_ENV=production 。

太多判斷式的 code ,就丟到 helper 裡面包起來,程式也會比較易讀。

helper 裡面的 method ,一定要寫 return ,避免呼叫後不曉得是哪段程式 return 結果。

arrow
arrow
    全站熱搜

    笨笨小蟹 發表在 痞客邦 留言(0) 人氣()