This is a repo that holds the frontend functionality for an E-Commerce website created by Halimah, Oskar, Diana and Alex.
Here are instructions for how to install this locally on the repo:
- Clone the repo
git clone https://github.com/fac29/hoda-e-commerce-frontend.git
- Navigate to the repo
cd hoda-e-commerce-frontend
- Install NPM packages
npm install
- Create a .env file
touch .env
and include the following line:
VITE_REQUEST_URL = "http://localhost:3000"
- Enter the following script to run the server in the development mode.
npm run dev
Prettier should be installed with other packages upon initialisation and utilise .prettierrc config file in the repo to ensure uniform formatting among contributors. For reference, the configuration is presented below:
{
"trailingComma": "es5",
"tabWidth": 4,
"singleQuote": true
}
This project utilises automated frontend testing using Cypress.
To run tests use:
npm run cy:run
To open Cypress use:
npm run cy:open