Skip to content

Latest commit

 

History

History
40 lines (34 loc) · 1.63 KB

README.md

File metadata and controls

40 lines (34 loc) · 1.63 KB

Online Thrift Store Website

this is supposed to be a website that people can add their second-hand products. And other people can contact them and buy the products. It's supposed to have a filtering functionility to view products based on city and category, etc.

API Design [WIP]

Routes:

  • GET "/" -> product list ordered by most recent
  • POST "/login"
  • POST "/logout"
  • POST "/signup"
  • POST "/products" -> create a new product
  • GET "/product/:productId" -> product detail page
    • if owner is logged in, how will they edit the listing?
  • GET "/user/:userId" -> profile page, see a list of all their products
  • DELETE "/products/:productId" -> delete product
  • POST "/products/:productId/edit" -> edit product
  • PUT "/products/:productId/image" -> change product image
  • PUT "/users/:userId/image" -> change user image

To do:

  • Login and Signup
  • replace callbacks with promises or async/await
  • uploading product image
  • implement the UI
  • make it responsive
  • product list pagination
  • use an ORM instead of raw SQL
  • logging errors in server logs
  • Unique constraint on user table should apply to both username and email
  • update counts for product list and categories
  • filtering
  • product editing / deletion
  • profile picture changing
  • validation & error handling
  • propagating errors to the client (catching and displaying them)
  • store the sessions in a session storage, Compatible Session Stores
  • localization