Skip to content

Conversation

@bbbouvier
Copy link

There are some situations when we need to make toJSON work in
different ways:

  • Communication with server where relations may be reduced to resource_uri
  • Template rendering where we need more information that the one we send to the server

Adding {full: true} to toJSON allows to avoid includeInJSON params and make a full
serialization of a model and its relations.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants