Tag: ruby

Daily Refactor #11: Extract action in ReportsController

I’m back up in the ReportsController now, getting ready to tackle some more of the duplication. The Refactoring Before 1 2 3 4 5 # config/routes.rb map.with_options :controller => 'reports', :action => 'issue_report', :conditions => {:method => :get} do |reports| reports.connect 'projects/:id/issues/report' reports.connect 'projects/:id/issues/report/:detail' end# config/routes.rb map.with_options :controller => 'reports', :action => 'issue_report', :conditions => …

Read more

Why I don’t use HAML or SASS

Seeing as the ERB vs HAML decision has now reached the armed conflict status, I figured that I would voice my opinions before it becomes yet another holy war. HAML, SASS, and ERB are all tools. From what I’ve seen, they are all very good quality and they all have their shortcomings. You can write …

Read more