Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve Form Validation handling #1

Open
pmbanugo opened this issue Dec 21, 2023 · 4 comments · May be fixed by #6
Open

Improve Form Validation handling #1

pmbanugo opened this issue Dec 21, 2023 · 4 comments · May be fixed by #6
Labels
good first issue Good for newcomers help wanted Extra attention is needed

Comments

@pmbanugo
Copy link
Owner

pmbanugo commented Dec 21, 2023

The forms currently only have basic client-side validation. The application should also do server-side validation, so that only valid data will be saved. It should ensure that:

  • required fields are submitted
  • the schedule value is properly checked based on the schedule type (e.g. cron expression or interval).
  • clear messaging for form validation errors.

This could be implemented in a simplistic way using epicweb-dev/invariant. An alternative is to use Conform and Valibot. The following guides by Kent Dodds shows how to use it in Remix.

@pmbanugo pmbanugo added help wanted Extra attention is needed good first issue Good for newcomers labels Dec 21, 2023
@pmbanugo
Copy link
Owner Author

pmbanugo commented Jan 1, 2024

Side note: perhaps root/apex domains like google.com should not be allowed because it's a waste of resource if they keep running and are not useful to the end user.

@pmbanugo pmbanugo changed the title Add Form Validation Improve Form Validation handling Jan 28, 2024
@abakermi
Copy link

@pmbanugo i will take that

@pmbanugo
Copy link
Owner Author

Just FYI, I’d like prefer if you used Valibot instead of Zod.

@abakermi
Copy link

@pmbanugo ok

abakermi added a commit to abakermi/cron-atlas that referenced this issue Jan 30, 2024
@pmbanugo pmbanugo linked a pull request Feb 2, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants