What is the best way to update or add a key to a map field - preserving existing key/values?
schema "authors" do
field :additional_data, :map
end
Reading through the docs and googling around, it seems my options are:
- Manually merge existing map with incoming map in my changeset.
- Convert my map field to an embedded schema and update it that way.
Are there other options I’m missing?
Thanks!