yogeshtakeo / team-pair-programming

0 stars 0 forks source link

Task 18: Login and Register #4

Open yogeshtakeo opened 1 year ago

yogeshtakeo commented 1 year ago

Task: Create Login, Register, and Home Pages with Authentication in React using TypeScript

Objective: Develop login and register pages with form handling and password validation checks, and create a home page that can only be accessed when the user is registered and logged on using authentication in React with TypeScript.

Task Overview

Task Details

  1. Project Setup:

    • Set up a new React project using Create React App or any other tool you prefer.
    • Configure TypeScript in the project by updating the configuration files and installing the necessary types.
  2. Create Login Page:

    • Create a login page component (LoginPage) that renders a login form.
    • Include form fields for email and password with TypeScript types.
    • Implement form handling with TypeScript to capture user input.
    • Log the credentials to the console after handling the form submission.
    • Optionally, implement password validation checks with TypeScript (e.g., minimum length, special characters).
  3. Create Register Page:

    • Create a register page component (RegisterPage) that renders a registration form.
    • Include form fields for name, email, password, and password confirmation with TypeScript types.
    • Implement form handling with TypeScript to capture user input.
    • Log the credentials to the console after handling the form submission.
    • Implement password validation checks with TypeScript (e.g., minimum length, special characters, password match).
  4. Create Home Page:

    • Create a home page component (HomePage) that can only be accessed when the user is registered and logged on.
    • Implement authentication functionality with TypeScript to determine if the user is logged in.
    • If the user is logged in, render the content of the home page. Otherwise, redirect them to the login page.
  5. Implement React Router:

    • Set up React Router in your application.
    • Configure routes for the login, register, and home pages.
    • Ensure that the appropriate page is rendered when the corresponding route is accessed.
  6. Test and Refine:

    • Start the development server and run the React project.
    • Verify that the login and register pages are rendered correctly.
    • Test the form handling functionality by entering credentials and checking if they are logged in the console.
    • Test the password validation checks by entering passwords of different strengths.
    • Test the home page authentication by logging in and accessing the home page.
    • Make adjustments and refinements to the design, form fields, authentication, or functionality as needed.

Task Submission

KabinaThapa commented 1 year ago

Kabina Thapa https://github.com/yogeshtakeo/team-pair-programming/tree/Kabina-Jharana/Login_and_Register

Image Image Image Image Image Image Image Image Image Image

Jharanatmg commented 1 year ago

Jharana Github - https://github.com/yogeshtakeo/team-pair-programming.git

Image Image Image Image Image Image

Image

sandessth commented 1 year ago

Team: Namkhang and Sandesh Git: https://github.com/yogeshtakeo/team-pair-programming/tree/nam-san/Task18-LR codeLogin codeRegisterHome git homepage registerError1 registerError2 registerError3 signInEmailError signInPasswordError

Namsla commented 1 year ago

Team: Namkhang and Sandesh Git: https://github.com/yogeshtakeo/team-pair-programming/tree/nam-san/Task18-LR

Screen Shot 2023-06-30 at 11 47 10 PM

249886476-4b18c541-958d-4d36-84cc-9cffc60b6519

249886478-344aee68-a86b-448f-b50a-6b8574011862

249886489-8fb03692-4ae2-4b7f-b0fa-17f63cb6e5ef

Screen Shot 2023-06-30 at 11 49 37 PM
ashmaupret100 commented 1 year ago

Team: Ashma and Dina Github Url: https://github.com/yogeshtakeo/team-pair-programming.git

Image Image Image Image Image Image