Create a readme with:
- title
- description
- all technologies used
- 1 or 2 screenshots
- setup instructions
- deployment instructions
d This is a Next.js vine e-commerce store project.
- Show all products in shop
- Single product page
- Show details of single product
- Increase/Decrease quantity of single product and add it to the cart
- Shopping cart
- Increase/Decrease quantity for products in the shopping cart
- Click on product to go back to the products page
- Delete product from cart
- Checkout
- Enter delivery and billing address
- Decide if billing address is different from billing address
- Chose delivery option (premium/standard)
- Buy now button leads to thank you page
- User accounts
- Login as admin or standard user
- Admin can change products description and price and can delete products from cart
- Standard users can buy products. Order is stored in the database
IMPORTANT: Cookies need to be activated
- Next.js
- Ley (for database migration)
- Cypress and Jest for testing
- Cookie management (cookies-js)
- Password management (argon2, crypto, CSFR)
First, make sure you have a postgres database up and running. Define your enviroment variables in an .env file
PGHOST=########
PGDATABASE=###########
PGUSERNAME=###########
PGPASSWORD=###########
CSRF_TOKEN_SECRET=###########
and run the migration via
yarn migrate up
Run npm or yarn:
npm
# or
yarn
Run the development server:
npm run dev
# or
yarn dev
Open http://localhost:3000 with your browser to see the result.
- Add environment variable to for CSRF on Heroku
- Clone repository
- Create a new project on Heroku and configure automatic deploy on push
- Connect it to your repository