Created
January 27, 2019 21:25
-
-
Save Bajena/e9fb845a6ffad74fc7346f8122c9230d to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class BaseSerializer < ActiveModel::Serializer | |
include AmsLazyRelationships::Core | |
end | |
class PostSerializer < BaseSerializer | |
attributes :id, :title | |
lazy_belongs_to :user | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment