hatchways / team-cherry

1 stars 1 forks source link

FE: Auth #8

Closed aeciorc closed 4 years ago

aeciorc commented 4 years ago

-two front-end routes (login and signup) -Protected routes -AuthFetch util (wraps fetch, parses json response, handles error like redirecting user to /login if status code Unauthorized or Forbidden -There is no landing page - redirect to login -Front-end validation as well: Examples: Password length >= 6, All fields are required, email is properly formatted (if you wrap signup and login in an HTML form, you can leverage some front-end HTML form validation, required and right typing) leverage error, helperText, and snackbars (material-ui) for showing validation errors, https://material- ui.com/components/snackbars/ + https://material-ui.com/components/text-fields/