Sha256: 173fbb8dc50b0a69cc6f35fe8741359355ee969df80bf9b6f0f4daf843a1351d
Contents?: true
Size: 176 Bytes
Versions: 59
Compression:
Stored size: 176 Bytes
Contents
class String def underscore self.gsub(/::/, '/'). gsub(/([A-Z]+)([A-Z][a-z])/,'\1_\2'). gsub(/([a-z\d])([A-Z])/,'\1_\2'). tr("-", "_"). downcase end end
Version data entries
59 entries across 59 versions & 9 rubygems