2

Somebody have an idea?

I have tried to find this option in Rabl Gem, but my searches have been unsuccessful. I think this is quite a common action and look forward to an early reply. Thanks!

extern.fx
  • 643
  • 1
  • 5
  • 9

1 Answers1

0

ActiveSupport::Inflector supports camlize out of the box, which you should be able to call on any string.

"active_model".camelize                # => "ActiveModel"
"active_model".camelize(:lower)        # => "activeModel"

See the link for complete documentation.

janders223
  • 3,123
  • 2
  • 22
  • 27