Casex v0.2.0 Casex.CamelCaseEncoder View Source

Format encoder for phoenix. Converts all the keys of the json data to camel case.

Usage

Add Casex.CamelCaseEncoder as json format encoder for phoenix:

# config.exs
config :phoenix, :format_encoders, json: Casex.CamelCaseEncoder

Now all outcoming json response bodies will be converted to camel case.

Link to this section Summary

Link to this section Functions

Link to this function

encode_to_iodata!(data)

View Source
encode_to_iodata!(data :: term()) :: iodata() | no_return()