起源於今天添加返回到之前頁面功能,用session實現,並加到applicationController下的afterfilter 上,然後發現在某些頁面死循環了。經過漫長的尋找終於發現問題原因:把skip_after_filter 寫做 skip_before_filter 了。
然後呢,就找到了這個插件,現在是gem了更方便:),據說很有名,看它個人介紹:
http://github.com/josevalim/rails-footnotes/tree/master
description
If you are developing in Rails you should know the plugin! It displays
footnotes in your application for easy debugging, such as sessions,
request parameters, cookies, filter chain, routes, queries, etc.
Even more, it contains links to open files directly in your editor including
your backtrace lines.
當然,肯定是我孤陋寡聞了,不過看功能也蠻強大的,試試吧!