File Size for Ecto v3.0.1 FileSize.Ecto.ByteWithUnit View Source
An Ecto type that represents a file size in bytes, supporting storage of different units. The value is stored as map in the database (i.e. jsonb when using PostgreSQL).
Example
defmodule MySchema do
use Ecto.Schema
schema "my_table" do
field :file_size, FileSize.Ecto.ByteWithUnit
end
end