Sha256: d191d46278f50f49d508b1e43bd30f00066962efcd02503a3e9123a5119306d2

Contents?: true

Size: 185 Bytes

Versions: 1

Compression:

Stored size: 185 Bytes

Contents

class String
  # Turns a lower_case_underscored_name into an UpperCaseCamelCaseName
  def classify
    self.gsub("_", " ").gsub(/\b('?[a-z])/) { $1.capitalize }.gsub(" ", "")
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
yad-0.0.4 lib/ext/string.rb