On my post model, I have implemented a simple validation def changeset(model, params \\ :empty) do model |> cast(params, @required_fields, @optional_fields) |> validate_length(:content, min: 2) |> validate_length(:content, max: 500) end On submitting the Post create form the view, I would like to show errors if there was something wrong from user submission, here is the view that renders the error