Skip to content

Instantly share code, notes, and snippets.

@pzaich
Created September 11, 2014 18:19
Show Gist options
  • Select an option

  • Save pzaich/cd577f4d3355a65815cc to your computer and use it in GitHub Desktop.

Select an option

Save pzaich/cd577f4d3355a65815cc to your computer and use it in GitHub Desktop.
my_custom_serializer
class MyCustomSerializerClass < ActiveModel::Serializer
class << self
# customize the associated object to the serializer
def model_class
SomeOtherClass
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment