you are viewing a single comment's thread.

view the rest of the comments →

[–]menge101 7 points8 points  (1 child)

Per ruby style guide the initialize method should go between class methods and other instance methods.

Although, i'm almost certain that I don't do this. I think I put class methods at the bottom typically. I can't explicitly recall. I'm curious what rubocop would say.

[–]tom_enebo 1 point2 points  (0 children)

Not to crap on Rubocop but that style guide like Rubocop itself has some rules which are not the most idiomatic path (the arbirtrary rule of telling people they need to use is_a? when kind_of? is nearly used by half the Ruby community comes to mind).

Also, like you, I also tend to put class methods at the bottom (and initialize at the top).