Skip to content

With validation errors? #2

@jrochkind

Description

@jrochkind

I use Rails as a back-end, and was looking for something like this, but with validation errors built-in too.

In particular, I want to display my validation errors that came from Rails validation on the backend, similar to simple_form.

Perhaps an errors prop to the parent form, and if errors[field_name] exists, it's written out in a standard way next to each input element. Along with a class added to the input wrapper, I guess, for styling.

Would you be amenable to such a PR?

Then there's the question of actual client-side validation, which I haven't thought through yet but also seems nice. Some way to attach your validation rules and error message, and have the errors likewise automatically appear next to the field, perhaps automically applied on onchange. Haven't fully thought this through, it's really a different issue, curious if you've thought about it though.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions