You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# By default, the type is the object's class name lowercased, pluralized, and dasherized,
# per the spec naming recommendations: http://jsonapi.org/recommendations/#naming
I was also not able to get the unformat_name override to work.
Usage:
class UserSerializer
include JSONAPI::Serializer
def unformat_name(attribute_name)
attribute_name.to_s.underscore
end
attribute :first_name
attribute :last_name
end
In the README.md:
However JSONAPI seems to have changed their recommendations to camelCase.
https://jsonapi.org/recommendations/#naming
Would be a breaking change so posting an issue about how to approach this before attempting a PR
The text was updated successfully, but these errors were encountered: