From the course: Build Modern Web Apps with React, Hooks, State Management, and APIs Using Vite or Next.js

Unlock this course with a free trial

Join today to access over 25,200 courses taught by industry experts.

Completing signup form

Completing signup form

Hello and welcome back, let's continue forward designing the JSX of our signup form. Our signup form is going to be looking like this. We are going to have a form defined in the on submit event of the form, we are going to call the handle submit event of our use form hook and inside that we are going to call the function onSubmit that we have created. Then we are going to have two fields on our form. Each field is going to have a label, an input field item as well as the error message showing under the input field. So let's get started with our form gsx. Over here, I am going to change this div to a form. We can get rid of this text and we can call the onSubmit function. This onSubmit function is going to call the handleSubmit and inside that we are going to call our onSubmit function that we created. Let's design this form as well. We are going to give a class name of max-width sm, a margin of x-axis to auto, overall padding of 6, a border to define the form, it will be rounded and…

Contents