ja_serializer v0.14.0 Release Notes
-
๐ฅ Breaking
- Only include attributes key when there are attributes present - #297
- Serializer attribute and relationship function overrides must be public. Previously there was an untested/undocumented way of overriding attributes with private functions, but this is no longer supported.
In other words, change this:
defmodule PostSerializer do use JaSerializer, dsl: true attributes [:html] defp html(post, _conn) do Earmark.to_html(post.body) end end
to this:
defmodule PostSerializer do use JaSerializer, dsl: true attributes [:html] def html(post, _conn) do Earmark.to_html(post.body) end end
๐ Features
- Read key format config value at runtime - #265
๐ Bug fixes
- Build pagination URLs using base url and request path - #281
- Issue rendering some ecto changeset errors - #275
- Handle the case where the end of a link is a URI fragment - #293
- Added missing @callback in Serializer - #294
- Consistent relation override - #299
- Fix compilation error when defining already inlined by compiler methods - #304
Misc
- Add .formatter.exs for consistent formatting
- Fixed compiler warnings
- Use
capture_io
in tests to make output less noisy