Sha256: 0c0bccf022bbb78e382ec88d34615254513cc9341dd4c38e507ca905b3973352

Contents?: true

Size: 207 Bytes

Versions: 4

Compression:

Stored size: 207 Bytes

Contents

# frozen_string_literal: true

module OAPI::Monkey
  refine Symbol do
    def camelize
      to_s.split("_").map(&:capitalize).join.tap do |a|
        a[0] = a[0].downcase
      end.to_sym
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
oapi-0.1.3 lib/oapi/monkey.rb
oapi-0.1.2 lib/oapi/monkey.rb
oapi-0.1.1 lib/oapi/monkey.rb
oapi-0.1.0 lib/oapi/monkey.rb