- Node.js, Express.js
- MongoDB, Mongoose
- React, Redux
- Tailwind CSS
This project uses MongoDB as the back-end database. There are two collections, User
and Listing
. As one user can have multiple listings, the _id
field of a user is stored as the userRef
in a listing to establish the relationship.
All images are stored in Firebase storage, and the correspondent urls are stored in the MongoDB collections as strings.
The YardGrown app uses cookie-based JSON Web Token (JWT) and Google Firebase authentication.
- Auth controller functions:
/server/controllers/auth.controller.js
Method | Endpoint | Parameter |
---|---|---|
POST |
/api/auth/sign-up | username, email, password |
POST |
/api/auth/sign-in | email password |
GET |
/api/auth/sign-out | none |
POST |
/api/auth/google | displayName avatar |
Method | Endpoint | Parameter |
---|---|---|
POST |
/api/user/update/:id | username, email, password, avatar |
DELETE |
/api/user/delete/:id | none |
GET |
/api/user/listings/:id | none |
Method | Endpoint | Parameter |
---|---|---|
GET |
/api/listing/retrieve | query string |
GET |
/api/listing/retrieve/:id | none |
POST |
/api/listing/create | form data |
POST |
/api/listing/update/:id | form data |
DELETE |
/api/listing/delete/:id | none |
keywords
: stringcategory
: stringcity
: stringdelivery
: booleanpickup
: booleansort
: 'createdAt' or 'price'order
: 'asc' of 'desc'limit
: numberstartIndex
: number
title
: stringdescription
: stringcategory
: stringprice
: numberdelivery
: booleanpickup
: booleancity
: stringemail
: stringimageUrls
: string[]
Background | Core | Accent | Special |
---|---|---|---|
#FDFAF6 |
#ABC4AA |
#C4D5C3 |
#C2BEB9 |
#FFFFFF |
#FAF1E6 |
#778977 |
#D57E7E |
#A9907E |
#F3DEBA |
||
#675D50 |
Usage | Family | Style | Size |
---|---|---|---|
Display title | Quicksand |
medium | 30px |
Card title | Quicksand |
bold | 18px |
Button text | Quicksand |
medium | 16px |
Paragraph text | Quicksand |
regular | 16px |
Footer text | Quicksand |
light | 14px |
Path | Page |
---|---|
/ |
home page |
/about |
about YardGrown |
/market |
all listings |
/lsiting/:id |
a single listing |
/mylistings/:id |
all listings of a user |
/create-listing |
create a new listing |
/edit-listing |
edit an existing listing |
/profile/:id |
profile of an user |
/sign-up |
sign up page |
/sign-in |
sign in page |