Class: String

Inherits:
Object
  • Object
show all
Defined in:
lib/ext/string.rb

Overview

Adds :titleize to string Class

Instance Method Summary collapse

Instance Method Details

#titleizeString

Returns:



6
7
8
# File 'lib/ext/string.rb', line 6

def titleize
  split.map(&:capitalize).join(" ")
end