This is a simple client side form validation. Check required, length, email and password match.
Create form UI. Show error messages under specific inputs. checkRequired() to accept array of inputs. checkLength() to check min and max length. checkEmail() to validate email with regex. checkPasswordsMatch() to match confirm password.
You can simply click here to preview the web app: https://techiemokhele.github.io/lets-validate-the-form/