Sha256: ad9e2187c0edaf54c4e4270ca792f594d9b97b10eaaeda0d661648e47a247f33

Contents?: true

Size: 103 Bytes

Versions: 31

Compression:

Stored size: 103 Bytes

Contents

class String
  def to_snake_case_sym
    self.gsub(/(.)([A-Z])/, '\1_\2').downcase.to_sym
  end
end

Version data entries

31 entries across 31 versions & 1 rubygems

Version Path
uia-1.0 lib/core_ext/string.rb
uia-0.8 lib/core_ext/string.rb
uia-0.7 lib/core_ext/string.rb
uia-0.7.alpha.1 lib/core_ext/string.rb
uia-0.6 lib/core_ext/string.rb
uia-0.5 lib/core_ext/string.rb
uia-0.4.4 lib/core_ext/string.rb
uia-0.4.3 lib/core_ext/string.rb
uia-0.4.2 lib/core_ext/string.rb
uia-0.4.1 lib/core_ext/string.rb
uia-0.4 lib/core_ext/string.rb
uia-0.3.3 lib/core_ext/string.rb
uia-0.3.2 lib/core_ext/string.rb
uia-0.3.1 lib/core_ext/string.rb
uia-0.3 lib/core_ext/string.rb
uia-0.2.1 lib/core_ext/string.rb
uia-0.2 lib/core_ext/string.rb
uia-0.1.3.1 lib/core_ext/string.rb
uia-0.1.3 lib/core_ext/string.rb
uia-0.1.2.3 lib/core_ext/string.rb