Sha256: aa52187fe9820aba1e6cc791904aed58906f288d8a0421be0c2911e83cd52244
Contents?: true
Size: 437 Bytes
Versions: 9
Compression:
Stored size: 437 Bytes
Contents
# Rgentpl module Rgentpl # Core Extensions module CoreExt String.class_eval do # Camelize # # @return [String] the camelized string def camelize split(/\s|-|_/).each { |s| s.capitalize! }.join('') end # Camelize! # # @return [String] the camelized string def camelize! replace(split(/\s|-|_/).each { |s| s.capitalize! }.join('')) end end end end
Version data entries
9 entries across 9 versions & 1 rubygems