That time I wrote a query with chained ruby methods weighing in at 41 lines and 2844 chars
14-Sep-2017 2878
First things first, I REFACTORED THIS NASTY MESS! And this is focused on how I got into the mess and some of the first things I did to addressed it.In my opinion Ruby is great and Rails is amazing. They make me a happy programmer and pretty productive. But I find keeping some solid rules in mind when coding is always good. I’ve started trying to hold myself to things like “more classes are better then fewer” and “keep methods short” - when I hit 10 lines really think about how to break it out.
That time I wrote a query with chained ruby methods weighing in at 41 lines and 2844 chars #ruby #rubydeveloper #rubyonrails #wrote #query #chained #methods #weighing #lines #chars https://rubyonrails.ba/link/that-time-i-wrote-a-query-with-chained-ruby-methods-weighing-in-at-41-lines-and-2844-chars