rails-api/active_model_serializers — pull request #699 by joaomdmoura (2014-10-26 07:13:55+00:00)
Title: Snake case attributes #507

Adding automatically treat to **CamelCased** attributes when using AMS Serializer gerenator.
It replaces the **CamelCased** attribute by a **snake_cased** one and defining a method to access the original attribute inside the serializer. For example:

```ruby
class PostSerializer < ActiveModel::Serializer
attributes :full_title, :body

has_many :comments

url :post

def full_title
obejct.fullTitle
end
end
```

As I wrote on README:
> **CamelCased** attributes will be converted to **snake_case** to ensure a AMS
> approach consistence. It will be done be automaticly creating a method in the
> generated serializer.

It is related to feature proposal #507 and other projects as [Ember APIKit Rails](dockyard/ember-appkit-rails#183)